mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-05 00:20:32 +00:00
scsi: sd_zbc: Let the SCSI core handle ILLEGAL REQUEST / ASC 0x21
scsi_io_completion() translates the sense key ILLEGAL REQUEST / ASC 0x21 into ACTION_FAIL. That means that setting cmd->allowed to zero in sd_zbc_complete() for this sense code / ASC combination is not necessary. Hence remove the code that resets cmd->allowed from sd_zbc_complete(). Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com> Cc: Damien Le Moal <damien.lemoal@wdc.com> Cc: Christoph Hellwig <hch@lst.de> Cc: Hannes Reinecke <hare@suse.com> Reviewed-by: Damien Le Moal <damien.lemoal@wdc.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
parent
354f113205
commit
c976562162
1 changed files with 0 additions and 10 deletions
|
@ -299,16 +299,6 @@ void sd_zbc_complete(struct scsi_cmnd *cmd, unsigned int good_bytes,
|
||||||
case REQ_OP_WRITE:
|
case REQ_OP_WRITE:
|
||||||
case REQ_OP_WRITE_ZEROES:
|
case REQ_OP_WRITE_ZEROES:
|
||||||
case REQ_OP_WRITE_SAME:
|
case REQ_OP_WRITE_SAME:
|
||||||
|
|
||||||
if (result &&
|
|
||||||
sshdr->sense_key == ILLEGAL_REQUEST &&
|
|
||||||
sshdr->asc == 0x21)
|
|
||||||
/*
|
|
||||||
* INVALID ADDRESS FOR WRITE error: It is unlikely that
|
|
||||||
* retrying write requests failed with any kind of
|
|
||||||
* alignement error will result in success. So don't.
|
|
||||||
*/
|
|
||||||
cmd->allowed = 0;
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case REQ_OP_ZONE_REPORT:
|
case REQ_OP_ZONE_REPORT:
|
||||||
|
|
Loading…
Reference in a new issue