[SCSI] scsi dh alua: handle report luns data changed in check sense callout
authorIlgu Hong <ilgu.hong@promise.com>
Fri, 30 Jan 2009 23:00:11 +0000 (17:00 -0600)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Thu, 12 Mar 2009 17:58:11 +0000 (12:58 -0500)
When we switch controllers the Intel Multi-Flex reports
REPORTED_LUNS_DATA_HAS_CHANGED. This patch just has us
retry the command.

Signed-off-by: Ilgu Hong <ilgu.hong@promise.com>
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
drivers/scsi/device_handler/scsi_dh_alua.c

index 31e1df5c366b6738a8f7336a3b6bd172bc3c07b0..dba154c8ff64acdd4d3ca5bcc6a3ccbb99fb783e 100644 (file)
@@ -461,6 +461,15 @@ static int alua_check_sense(struct scsi_device *sdev,
                         */
                        return ADD_TO_MLQUEUE;
                }
+               if (sense_hdr->asc == 0x3f && sense_hdr->ascq == 0x0e) {
+                       /*
+                        * REPORTED_LUNS_DATA_HAS_CHANGED is reported
+                        * when switching controllers on targets like
+                        * Intel Multi-Flex. We can just retry.
+                        */
+                       return ADD_TO_MLQUEUE;
+               }
+
                break;
        }