aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla2xxx/qla_mbx.c
diff options
context:
space:
mode:
authorAndrew Vasquez <andrew.vasquez@qlogic.com>2008-02-28 17:06:11 -0500
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2008-03-03 14:11:35 -0500
commit00a537b8204c7360852379b4d56adbeedecc9bb9 (patch)
treea48270a597780e4d830b397ccb075349a093cbcf /drivers/scsi/qla2xxx/qla_mbx.c
parent3e8ce320cfc6cc10a7b99d8d6508d00bde20fdb7 (diff)
[SCSI] qla2xxx: Correct usage of inconsistent timeout values while issuing ELS commands.
The original code would incorrectly hardcode ELS timeout values rather than using the traditional '2 * r_a_tov' value. In some cases, the hardcoded values would be larger than the mailbox-command-timeout and result in a needless BIG_HAMMER (ISP reset), the typical recovery mechanism employed in such cases. The second defect in the original code was in the assignment of the default 'ha->r_a_tov' to twice the traditional value. Correct this by setting the value to 10 seconds. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_mbx.c')
-rw-r--r--drivers/scsi/qla2xxx/qla_mbx.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c
index 99d29fff836d..bb103580e1ba 100644
--- a/drivers/scsi/qla2xxx/qla_mbx.c
+++ b/drivers/scsi/qla2xxx/qla_mbx.c
@@ -2206,7 +2206,7 @@ qla24xx_abort_target(fc_port_t *fcport)
2206 tsk->p.tsk.entry_type = TSK_MGMT_IOCB_TYPE; 2206 tsk->p.tsk.entry_type = TSK_MGMT_IOCB_TYPE;
2207 tsk->p.tsk.entry_count = 1; 2207 tsk->p.tsk.entry_count = 1;
2208 tsk->p.tsk.nport_handle = cpu_to_le16(fcport->loop_id); 2208 tsk->p.tsk.nport_handle = cpu_to_le16(fcport->loop_id);
2209 tsk->p.tsk.timeout = __constant_cpu_to_le16(25); 2209 tsk->p.tsk.timeout = cpu_to_le16(ha->r_a_tov / 10 * 2);
2210 tsk->p.tsk.control_flags = __constant_cpu_to_le32(TCF_TARGET_RESET); 2210 tsk->p.tsk.control_flags = __constant_cpu_to_le32(TCF_TARGET_RESET);
2211 tsk->p.tsk.port_id[0] = fcport->d_id.b.al_pa; 2211 tsk->p.tsk.port_id[0] = fcport->d_id.b.al_pa;
2212 tsk->p.tsk.port_id[1] = fcport->d_id.b.area; 2212 tsk->p.tsk.port_id[1] = fcport->d_id.b.area;