Commit 7b25bdb1 authored by Hannes Reinecke's avatar Hannes Reinecke Committed by Martin K. Petersen

scsi: NCR5380: Fold SCSI message ABORT onto DID_ABORT

The message byte can take only two values, COMMAND_COMPLETE and ABORT.  So
we can easily map ABORT to DID_ABORT and not set the message byte.

Link: https://lore.kernel.org/r/20210427083046.31620-16-hare@suse.deSigned-off-by: default avatarHannes Reinecke <hare@suse.de>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 54c29086
......@@ -1815,6 +1815,8 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
switch (tmp) {
case ABORT:
set_host_byte(cmd, DID_ABORT);
/* fallthrough */
case COMMAND_COMPLETE:
/* Accept message by clearing ACK */
sink = 1;
......@@ -1826,9 +1828,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
hostdata->connected = NULL;
hostdata->busy[scmd_id(cmd)] &= ~(1 << cmd->device->lun);
cmd->result &= ~0xffff;
cmd->result |= cmd->SCp.Status;
cmd->result |= cmd->SCp.Message << 8;
set_status_byte(cmd, cmd->SCp.Status);
set_resid_from_SCp(cmd);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment