]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: aha152x: Do not set message byte when calling scsi_done()
authorHannes Reinecke <hare@suse.de>
Tue, 27 Apr 2021 08:30:36 +0000 (10:30 +0200)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 1 Jun 2021 02:48:23 +0000 (22:48 -0400)
commit4a024fc2717e708fe48e29437c96117462aa8105
tree5fd92e37959cd32cfcf40d516c1d5a805ab77d65
parenteef0812e8350fede45f7225ac4b0012364dd8047
scsi: aha152x: Do not set message byte when calling scsi_done()

The done() function is called with a host_byte indicating the actual error
when the message byte is set. As the host byte takes precedence during
error recovery we can drop setting the message byte if the host byte is
set, too.  The only other case is when the host byte is DID_OK, but in that
case the message byte is always COMMAND_COMPLETE (i.e. 0), so we can drop
it there, too.

Link: https://lore.kernel.org/r/20210427083046.31620-31-hare@suse.de
Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/aha152x.c