If initiator or target reject the I/O due to DIF errors there is no point in retrying. Signed-off-by: Martin K. Petersen <martin.petersen@xxxxxxxxxx> --- 2 files changed, 7 insertions(+) drivers/scsi/scsi_error.c | 3 +++ drivers/scsi/scsi_lib.c | 4 ++++ diff --git a/drivers/scsi/scsi_error.c b/drivers/scsi/scsi_error.c --- a/drivers/scsi/scsi_error.c +++ b/drivers/scsi/scsi_error.c @@ -333,6 +333,9 @@ static int scsi_check_sense(struct scsi_ return /* soft_error */ SUCCESS; case ABORTED_COMMAND: + if (sshdr.asc == 0x10) /* DIF */ + return SUCCESS; + return NEEDS_RETRY; case NOT_READY: case UNIT_ATTENTION: diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c @@ -945,6 +945,10 @@ void scsi_io_completion(struct scsi_cmnd scsi_requeue_command(q, cmd); return; } else { + if (sshdr.asc == 0x10) { /* DIF */ + scsi_print_result(cmd); + scsi_print_sense("", cmd); + } scsi_end_request(cmd, -EIO, this_count, 1); return; } -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html