From: Giridhar Malavali Date: Wed, 23 Feb 2011 23:27:11 +0000 (-0800) Subject: [SCSI] qla2xxx: Don't wait for active mailbox command completion when firmware is... X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=862cd01e5c2f3f5cf1ca989aa1184d61b6988ba2;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git [SCSI] qla2xxx: Don't wait for active mailbox command completion when firmware is hung. Signed-off-by: Giridhar Malavali Signed-off-by: Madhuranath Iyengar Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c index a7f7346c783a..b4a82b5f0f8b 100644 --- a/drivers/scsi/qla2xxx/qla_mbx.c +++ b/drivers/scsi/qla2xxx/qla_mbx.c @@ -71,6 +71,13 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp) return QLA_FUNCTION_TIMEOUT; } + if (ha->flags.isp82xx_fw_hung) { + /* Setting Link-Down error */ + mcp->mb[0] = MBS_LINK_DOWN_ERROR; + rval = QLA_FUNCTION_FAILED; + goto premature_exit; + } + /* * Wait for active mailbox commands to finish by waiting at most tov * seconds. This is to serialize actual issuing of mailbox cmds during @@ -83,13 +90,6 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp) return QLA_FUNCTION_TIMEOUT; } - if (ha->flags.isp82xx_fw_hung) { - /* Setting Link-Down error */ - mcp->mb[0] = MBS_LINK_DOWN_ERROR; - rval = QLA_FUNCTION_FAILED; - goto premature_exit; - } - ha->flags.mbox_busy = 1; /* Save mailbox command for debug */ ha->mcp = mcp;