]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - src/patches/suse-2.6.27.31/patches.fixes/scsi_dh-retry-on-UNIT_ATTENTION
Reenabled linux-xen, added patches for Xen Kernel Version 2.6.27.31,
[people/pmueller/ipfire-2.x.git] / src / patches / suse-2.6.27.31 / patches.fixes / scsi_dh-retry-on-UNIT_ATTENTION
diff --git a/src/patches/suse-2.6.27.31/patches.fixes/scsi_dh-retry-on-UNIT_ATTENTION b/src/patches/suse-2.6.27.31/patches.fixes/scsi_dh-retry-on-UNIT_ATTENTION
new file mode 100644 (file)
index 0000000..78f8631
--- /dev/null
@@ -0,0 +1,29 @@
+From: Hannes Reinecke <hare@suse.de>
+Subject: scsi_dh_rdac does not retry MODE SENSE on UNIT ATTENTION
+References: bnc#464155
+
+When we encounter a UNIT ATTENTION sense code we should always retry
+the command; the ASC and ASQ codes are irrelevant here.
+
+Signed-off-by: Hannes Reinecke <hare@suse.de>
+Signed-off-by: Chandra Seetharaman <sekharan@us.ibm.com>
+
+diff --git a/drivers/scsi/device_handler/scsi_dh_rdac.c b/drivers/scsi/device_handler/scsi_dh_rdac.c
+index f25a03e..3ab052d 100644
+--- a/drivers/scsi/device_handler/scsi_dh_rdac.c
++++ b/drivers/scsi/device_handler/scsi_dh_rdac.c
+@@ -459,11 +459,10 @@ static int mode_select_handle_sense(struct scsi_device *sdev,
+       sense = (sense_hdr.sense_key << 16) | (sense_hdr.asc << 8) |
+                       sense_hdr.ascq;
+       /* If it is retryable failure, submit the c9 inquiry again */
+-      if (sense == 0x59136 || sense == 0x68b02 || sense == 0xb8b02 ||
+-                          sense == 0x62900) {
++      if (sense_hdr.sense_key == 6 || sense == 0x59136 || sense == 0xb8b02) {
+               /* 0x59136    - Command lock contention
+-               * 0x[6b]8b02 - Quiesense in progress or achieved
+-               * 0x62900    - Power On, Reset, or Bus Device Reset
++               * 0xb8b02    - Quiescense achieved
++               * 0x6xxxx    - Unit Attention
+                */
+               err = SCSI_DH_RETRY;
+       }