Commit 987d7d3d authored by Mike Christie's avatar Mike Christie Committed by Martin K. Petersen

scsi: core: Retry INQUIRY after timeout

Description from: Martin Wilck <mwilck@suse.com>:

The SCSI mid layer doesn't retry commands after DID_TIME_OUT (see
scsi_noretry_cmd()). Packet loss in the fabric can cause spurious timeouts
during SCSI device probing, causing device probing to fail. This has been
observed in FCoE uplink failover tests, for example.

This patch fixes the issue by retrying the INQUIRY.
Signed-off-by: default avatarMike Christie <michael.christie@oracle.com>
Link: https://lore.kernel.org/r/20240123002220.129141-4-michael.christie@oracle.comReviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Reviewed-by: default avatarMartin Wilck <mwilck@suse.com>
Acked-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 2a1f96f6
......@@ -665,6 +665,10 @@ static int scsi_probe_lun(struct scsi_device *sdev, unsigned char *inq_result,
.asc = 0x29,
.result = SAM_STAT_CHECK_CONDITION,
},
{
.allowed = 1,
.result = DID_TIME_OUT << 16,
},
{}
};
struct scsi_failures failures = {
......
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