[SCSI] hpsa: Retry commands completing with a sense key of ABORTED_COMMAND
authorMatt Gates <matthew.gates@hp.com>
Thu, 4 Feb 2010 14:43:00 +0000 (08:43 -0600)
committerJames Bottomley <James.Bottomley@suse.de>
Wed, 17 Feb 2010 19:21:31 +0000 (13:21 -0600)
Signed-off-by: Matt Gates <matthew.gates@hp.com>
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/hpsa.c

index bcc51f9d3903aaffcef35dfe838ae52de0f55edd..d07b3d3f11a42544356c5ac3d7b82a1488478ea3 100644 (file)
@@ -1037,8 +1037,15 @@ static void complete_scsi_command(struct CommandList *cp,
                                        break;
                                }
                        }
-
-
+                       if (sense_key == ABORTED_COMMAND) {
+                               /* Aborted command is retryable */
+                               dev_warn(&h->pdev->dev, "cp %p "
+                                       "has check condition: aborted command: "
+                                       "ASC: 0x%x, ASCQ: 0x%x\n",
+                                       cp, asc, ascq);
+                               cmd->result = DID_SOFT_ERROR << 16;
+                               break;
+                       }
                        /* Must be some other type of check condition */
                        dev_warn(&h->pdev->dev, "cp %p has check condition: "
                                        "unknown type: "