aboutsummaryrefslogtreecommitdiff
path: root/drivers/scsi/qla2xxx
diff options
context:
space:
mode:
authorAndrew Vasquez <andrew.vasquez@qlogic.com>2005-09-20 13:25:53 -0700
committerJames Bottomley <jejb@mulgrave.(none)>2005-10-28 13:25:26 -0500
commit9a41a62b74388827998253d62c58707e63cc5874 (patch)
tree71d71691575f75df21569f60dcb1c7d6e19ebd69 /drivers/scsi/qla2xxx
parent7a691bd34130920bef4d118a3f555ebc48544a63 (diff)
[SCSI] qla2xxx: remove eh_active checks in qla2xxx error handling
Here's a patch which drops the eh_active checks in the qla2xxx eh_handler callbacks. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/qla2xxx')
-rw-r--r--drivers/scsi/qla2xxx/qla_os.c41
1 files changed, 15 insertions, 26 deletions
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 74a26a4a69b..92976c235ee 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -762,29 +762,19 @@ qla2xxx_eh_device_reset(struct scsi_cmnd *cmd)
goto eh_dev_reset_done;
}
- /*
- * If we are coming down the EH path, wait for all commands to
- * complete for the device.
- */
- if (cmd->device->host->eh_active) {
- if (qla2x00_eh_wait_for_pending_target_commands(ha, id))
- ret = FAILED;
-
- if (ret == FAILED) {
- DEBUG3(printk("%s(%ld): failed while waiting for "
- "commands\n", __func__, ha->host_no));
- qla_printk(KERN_INFO, ha,
- "%s: failed while waiting for commands\n",
- __func__);
-
- goto eh_dev_reset_done;
- }
- }
-
- qla_printk(KERN_INFO, ha,
- "scsi(%ld:%d:%d): DEVICE RESET SUCCEEDED.\n", ha->host_no, id, lun);
+ /* Flush outstanding commands. */
+ if (qla2x00_eh_wait_for_pending_target_commands(ha, id))
+ ret = FAILED;
+ if (ret == FAILED) {
+ DEBUG3(printk("%s(%ld): failed while waiting for commands\n",
+ __func__, ha->host_no));
+ qla_printk(KERN_INFO, ha,
+ "%s: failed while waiting for commands\n", __func__);
+ } else
+ qla_printk(KERN_INFO, ha,
+ "scsi(%ld:%d:%d): DEVICE RESET SUCCEEDED.\n", ha->host_no,
+ id, lun);
-eh_dev_reset_done:
return ret;
}
@@ -886,10 +876,9 @@ qla2xxx_eh_bus_reset(struct scsi_cmnd *cmd)
if (ret == FAILED)
goto eh_bus_reset_done;
- /* Waiting for our command in done_queue to be returned to OS.*/
- if (cmd->device->host->eh_active)
- if (!qla2x00_eh_wait_for_pending_commands(ha))
- ret = FAILED;
+ /* Flush outstanding commands. */
+ if (!qla2x00_eh_wait_for_pending_commands(ha))
+ ret = FAILED;
eh_bus_reset_done:
qla_printk(KERN_INFO, ha, "%s: reset %s\n", __func__,