]> git.ipfire.org Git - ipfire-2.x.git/blame - src/patches/suse-2.6.27.39/patches.fixes/scsi_dh-retry-on-UNIT_ATTENTION
Imported linux-2.6.27.39 suse/xen patches.
[ipfire-2.x.git] / src / patches / suse-2.6.27.39 / patches.fixes / scsi_dh-retry-on-UNIT_ATTENTION
CommitLineData
2cb7cef9
BS
1From: Hannes Reinecke <hare@suse.de>
2Subject: scsi_dh_rdac does not retry MODE SENSE on UNIT ATTENTION
3References: bnc#464155
4
5When we encounter a UNIT ATTENTION sense code we should always retry
6the command; the ASC and ASQ codes are irrelevant here.
7
8Signed-off-by: Hannes Reinecke <hare@suse.de>
9Signed-off-by: Chandra Seetharaman <sekharan@us.ibm.com>
10
11diff --git a/drivers/scsi/device_handler/scsi_dh_rdac.c b/drivers/scsi/device_handler/scsi_dh_rdac.c
12index f25a03e..3ab052d 100644
13--- a/drivers/scsi/device_handler/scsi_dh_rdac.c
14+++ b/drivers/scsi/device_handler/scsi_dh_rdac.c
15@@ -459,11 +459,10 @@ static int mode_select_handle_sense(struct scsi_device *sdev,
16 sense = (sense_hdr.sense_key << 16) | (sense_hdr.asc << 8) |
17 sense_hdr.ascq;
18 /* If it is retryable failure, submit the c9 inquiry again */
19- if (sense == 0x59136 || sense == 0x68b02 || sense == 0xb8b02 ||
20- sense == 0x62900) {
21+ if (sense_hdr.sense_key == 6 || sense == 0x59136 || sense == 0xb8b02) {
22 /* 0x59136 - Command lock contention
23- * 0x[6b]8b02 - Quiesense in progress or achieved
24- * 0x62900 - Power On, Reset, or Bus Device Reset
25+ * 0xb8b02 - Quiescense achieved
26+ * 0x6xxxx - Unit Attention
27 */
28 err = SCSI_DH_RETRY;
29 }