* [PATCH 01/14] qla2xxx: Remove qla2x00_wait_for_loop_ready function.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 02/14] qla2xxx: Check for SCSI status on underruns Chad Dupuis
` (12 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Saurav Kashyap <saurav.kashyap@qlogic.com>
This function can wait for 5min under certain scenarios. One of them is when
the port is down from switch and bus reset is issued. The bus reset used to
wait for 5 minutes for the loop and upper layer callers used to hang and give
stack trace because of getting stuck for 120 sec. Its legacy code that was used
when the driver used to do queuing of the commands.
Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_os.c | 70 ++--------------------------------------
1 files changed, 4 insertions(+), 66 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index fd14c7b..93673d3 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -814,49 +814,6 @@ qla2x00_wait_for_chip_reset(scsi_qla_host_t *vha)
return return_status;
}
-/*
- * qla2x00_wait_for_loop_ready
- * Wait for MAX_LOOP_TIMEOUT(5 min) value for loop
- * to be in LOOP_READY state.
- * Input:
- * ha - pointer to host adapter structure
- *
- * Note:
- * Does context switching-Release SPIN_LOCK
- * (if any) before calling this routine.
- *
- *
- * Return:
- * Success (LOOP_READY) : 0
- * Failed (LOOP_NOT_READY) : 1
- */
-static inline int
-qla2x00_wait_for_loop_ready(scsi_qla_host_t *vha)
-{
- int return_status = QLA_SUCCESS;
- unsigned long loop_timeout ;
- struct qla_hw_data *ha = vha->hw;
- scsi_qla_host_t *base_vha = pci_get_drvdata(ha->pdev);
-
- /* wait for 5 min at the max for loop to be ready */
- loop_timeout = jiffies + (MAX_LOOP_TIMEOUT * HZ);
-
- while ((!atomic_read(&base_vha->loop_down_timer) &&
- atomic_read(&base_vha->loop_state) == LOOP_DOWN) ||
- atomic_read(&base_vha->loop_state) != LOOP_READY) {
- if (atomic_read(&base_vha->loop_state) == LOOP_DEAD) {
- return_status = QLA_FUNCTION_FAILED;
- break;
- }
- msleep(1000);
- if (time_after_eq(jiffies, loop_timeout)) {
- return_status = QLA_FUNCTION_FAILED;
- break;
- }
- }
- return (return_status);
-}
-
static void
sp_get(struct srb *sp)
{
@@ -1035,12 +992,6 @@ __qla2xxx_eh_generic_reset(char *name, enum nexus_wait_type type,
"Wait for hba online failed for cmd=%p.\n", cmd);
goto eh_reset_failed;
}
- err = 1;
- if (qla2x00_wait_for_loop_ready(vha) != QLA_SUCCESS) {
- ql_log(ql_log_warn, vha, 0x800b,
- "Wait for loop ready failed for cmd=%p.\n", cmd);
- goto eh_reset_failed;
- }
err = 2;
if (do_reset(fcport, cmd->device->lun, cmd->request->cpu + 1)
!= QLA_SUCCESS) {
@@ -1137,10 +1088,9 @@ qla2xxx_eh_bus_reset(struct scsi_cmnd *cmd)
goto eh_bus_reset_done;
}
- if (qla2x00_wait_for_loop_ready(vha) == QLA_SUCCESS) {
- if (qla2x00_loop_reset(vha) == QLA_SUCCESS)
- ret = SUCCESS;
- }
+ if (qla2x00_loop_reset(vha) == QLA_SUCCESS)
+ ret = SUCCESS;
+
if (ret == FAILED)
goto eh_bus_reset_done;
@@ -1206,15 +1156,6 @@ qla2xxx_eh_host_reset(struct scsi_cmnd *cmd)
if (qla2x00_wait_for_reset_ready(vha) != QLA_SUCCESS)
goto eh_host_reset_lock;
- /*
- * Fixme-may be dpc thread is active and processing
- * loop_resync,so wait a while for it to
- * be completed and then issue big hammer.Otherwise
- * it may cause I/O failure as big hammer marks the
- * devices as lost kicking of the port_down_timer
- * while dpc is stuck for the mailbox to complete.
- */
- qla2x00_wait_for_loop_ready(vha);
if (vha != base_vha) {
if (qla2x00_vp_abort_isp(vha))
goto eh_host_reset_lock;
@@ -1297,16 +1238,13 @@ qla2x00_loop_reset(scsi_qla_host_t *vha)
atomic_set(&vha->loop_state, LOOP_DOWN);
atomic_set(&vha->loop_down_timer, LOOP_DOWN_TIME);
qla2x00_mark_all_devices_lost(vha, 0);
- qla2x00_wait_for_loop_ready(vha);
}
if (ha->flags.enable_lip_reset) {
ret = qla2x00_lip_reset(vha);
- if (ret != QLA_SUCCESS) {
+ if (ret != QLA_SUCCESS)
ql_dbg(ql_dbg_taskm, vha, 0x802e,
"lip_reset failed (%d).\n", ret);
- } else
- qla2x00_wait_for_loop_ready(vha);
}
/* Issue marker command only when we are going to start the I/O */
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 02/14] qla2xxx: Check for SCSI status on underruns.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
2011-11-18 17:02 ` [PATCH 01/14] qla2xxx: Remove qla2x00_wait_for_loop_ready function Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 03/14] qla2xxx: Don't call alloc_fw_dump for ISP82XX Chad Dupuis
` (11 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Arun Easi <arun.easi@qlogic.com>
Signed-off-by: Arun Easi <arun.easi@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_isr.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c
index 2516adf..7b91b29 100644
--- a/drivers/scsi/qla2xxx/qla_isr.c
+++ b/drivers/scsi/qla2xxx/qla_isr.c
@@ -1741,7 +1741,7 @@ qla2x00_status_entry(scsi_qla_host_t *vha, struct rsp_que *rsp, void *pkt)
resid, scsi_bufflen(cp));
cp->result = DID_ERROR << 16 | lscsi_status;
- break;
+ goto check_scsi_status;
}
if (!lscsi_status &&
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 03/14] qla2xxx: Don't call alloc_fw_dump for ISP82XX.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
2011-11-18 17:02 ` [PATCH 01/14] qla2xxx: Remove qla2x00_wait_for_loop_ready function Chad Dupuis
2011-11-18 17:02 ` [PATCH 02/14] qla2xxx: Check for SCSI status on underruns Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 04/14] qla2xxx: Revert back the request queue mapping to request queue 0 Chad Dupuis
` (10 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Saurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_init.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c
index f03e915..54ea68c 100644
--- a/drivers/scsi/qla2xxx/qla_init.c
+++ b/drivers/scsi/qla2xxx/qla_init.c
@@ -1509,7 +1509,8 @@ enable_82xx_npiv:
&ha->fw_xcb_count, NULL, NULL,
&ha->max_npiv_vports, NULL);
- if (!fw_major_version && ql2xallocfwdump)
+ if (!fw_major_version && ql2xallocfwdump
+ && !IS_QLA82XX(ha))
qla2x00_alloc_fw_dump(vha);
}
} else {
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 04/14] qla2xxx: Revert back the request queue mapping to request queue 0.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (2 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 03/14] qla2xxx: Don't call alloc_fw_dump for ISP82XX Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 05/14] qla2xxx: Stop unconditional completion of mailbox commands issued in interrupt mode during firmware hang Chad Dupuis
` (9 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Giridhar Malavali <giridhar.malavali@qlogic.com>
If there is an error creating multiple response queues then we need to revert
the request queue mapping back to request queue 0.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_os.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 93673d3..01c8700 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -423,6 +423,7 @@ fail2:
qla25xx_delete_queues(vha);
destroy_workqueue(ha->wq);
ha->wq = NULL;
+ vha->req = ha->req_q_map[0];
fail:
ha->mqenable = 0;
kfree(ha->req_q_map);
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 05/14] qla2xxx: Stop unconditional completion of mailbox commands issued in interrupt mode during firmware hang.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (3 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 04/14] qla2xxx: Revert back the request queue mapping to request queue 0 Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 06/14] qla2xxx: Enable Minidump by default with default capture mask 0x1f Chad Dupuis
` (8 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_nx.c | 5 ++++-
drivers/scsi/qla2xxx/qla_os.c | 5 ++++-
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_nx.c b/drivers/scsi/qla2xxx/qla_nx.c
index 94bded5..d2005c3 100644
--- a/drivers/scsi/qla2xxx/qla_nx.c
+++ b/drivers/scsi/qla2xxx/qla_nx.c
@@ -4075,7 +4075,10 @@ qla82xx_chip_reset_cleanup(scsi_qla_host_t *vha)
ha->flags.isp82xx_fw_hung = 1;
if (ha->flags.mbox_busy) {
ha->flags.mbox_int = 1;
- complete(&ha->mbx_intr_comp);
+ if (test_bit(MBX_INTR_WAIT,
+ &ha->mbx_cmd_flags)) {
+ complete(&ha->mbx_intr_comp);
+ }
}
break;
}
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 01c8700..abec1dd 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -4014,7 +4014,10 @@ qla2xxx_pci_error_detected(struct pci_dev *pdev, pci_channel_state_t state)
ql_dbg(ql_dbg_aer, vha, 0x9001,
"Due to pci channel io frozen, doing premature "
"completion of mbx command.\n");
- complete(&ha->mbx_intr_comp);
+ if (test_bit(MBX_INTR_WAIT,
+ &ha->mbx_cmd_flags)) {
+ complete(&ha->mbx_intr_comp);
+ }
}
}
qla2x00_free_irqs(vha);
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 06/14] qla2xxx: Enable Minidump by default with default capture mask 0x1f.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (4 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 05/14] qla2xxx: Stop unconditional completion of mailbox commands issued in interrupt mode during firmware hang Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 07/14] qla2xxx: Return the correct value for a mailbox command if 82xx is in reset recovery Chad Dupuis
` (7 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_os.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index abec1dd..71d6259 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -201,12 +201,12 @@ MODULE_PARM_DESC(ql2xmdcapmask,
"Set the Minidump driver capture mask level. "
"Default is 0x7F - Can be set to 0x3, 0x7, 0xF, 0x1F, 0x7F.");
-int ql2xmdenable;
+int ql2xmdenable = 1;
module_param(ql2xmdenable, int, S_IRUGO);
MODULE_PARM_DESC(ql2xmdenable,
"Enable/disable MiniDump. "
- "0 (Default) - MiniDump disabled. "
- "1 - MiniDump enabled.");
+ "0 - MiniDump disabled. "
+ "1 (Default) - MiniDump enabled.");
/*
* SCSI host template entry points
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 07/14] qla2xxx: Return the correct value for a mailbox command if 82xx is in reset recovery.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (5 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 06/14] qla2xxx: Enable Minidump by default with default capture mask 0x1f Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 08/14] qla2xxx: Display IPE error message for ISP82xx Chad Dupuis
` (6 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Andrew Vasquez <andrew.vasquez@qlogic.com>
We need to return QLA_FUNCTION_TIMEOUT immediately otherwise we mess up the
mailbox command state machine.
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_mbx.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c
index 3b3cec9..f965a57 100644
--- a/drivers/scsi/qla2xxx/qla_mbx.c
+++ b/drivers/scsi/qla2xxx/qla_mbx.c
@@ -79,8 +79,7 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp)
mcp->mb[0] = MBS_LINK_DOWN_ERROR;
ql_log(ql_log_warn, base_vha, 0x1004,
"FW hung = %d.\n", ha->flags.isp82xx_fw_hung);
- rval = QLA_FUNCTION_FAILED;
- goto premature_exit;
+ return QLA_FUNCTION_TIMEOUT;
}
/*
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 08/14] qla2xxx: Display IPE error message for ISP82xx.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (6 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 07/14] qla2xxx: Return the correct value for a mailbox command if 82xx is in reset recovery Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 09/14] qla2xxx: Encapsulate prematurely completing mailbox commands during ISP82xx firmware hang Chad Dupuis
` (5 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_nx.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_nx.c b/drivers/scsi/qla2xxx/qla_nx.c
index d2005c3..d025582 100644
--- a/drivers/scsi/qla2xxx/qla_nx.c
+++ b/drivers/scsi/qla2xxx/qla_nx.c
@@ -3858,6 +3858,11 @@ void qla82xx_watchdog(scsi_qla_host_t *vha)
QLA82XX_CRB_PEG_NET_3 + 0x3c),
qla82xx_rd_32(ha,
QLA82XX_CRB_PEG_NET_4 + 0x3c));
+ if(LSW(MSB(halt_status)) == 0x67)
+ ql_log(ql_log_warn, vha, 0xb052,
+ "Firmware aborted with "
+ "error code 0x00006700. Device is "
+ "being reset.\n");
if (halt_status & HALT_STATUS_UNRECOVERABLE) {
set_bit(ISP_UNRECOVERABLE,
&vha->dpc_flags);
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 09/14] qla2xxx: Encapsulate prematurely completing mailbox commands during ISP82xx firmware hang.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (7 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 08/14] qla2xxx: Display IPE error message for ISP82xx Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 10/14] qla2xxx: Clear mailbox busy flag during premature mailbox completion for ISP82xx Chad Dupuis
` (4 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_dbg.c | 6 +++---
drivers/scsi/qla2xxx/qla_gbl.h | 1 +
drivers/scsi/qla2xxx/qla_nx.c | 33 ++++++++++++++++-----------------
drivers/scsi/qla2xxx/qla_os.c | 12 ++----------
4 files changed, 22 insertions(+), 30 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_dbg.c b/drivers/scsi/qla2xxx/qla_dbg.c
index 9df4787..e320d54 100644
--- a/drivers/scsi/qla2xxx/qla_dbg.c
+++ b/drivers/scsi/qla2xxx/qla_dbg.c
@@ -17,12 +17,12 @@
* | Queue Command and IO tracing | 0x302e | 0x3008 |
* | DPC Thread | 0x401c | |
* | Async Events | 0x5059 | |
- * | Timer Routines | 0x600d | |
+ * | Timer Routines | 0x6010 | 0x600e,0x600f |
* | User Space Interactions | 0x709d | |
- * | Task Management | 0x8041 | |
+ * | Task Management | 0x8041 | 0x800b |
* | AER/EEH | 0x900f | |
* | Virtual Port | 0xa007 | |
- * | ISP82XX Specific | 0xb051 | |
+ * | ISP82XX Specific | 0xb052 | |
* | MultiQ | 0xc00b | |
* | Misc | 0xd00b | |
* ----------------------------------------------------------------------
diff --git a/drivers/scsi/qla2xxx/qla_gbl.h b/drivers/scsi/qla2xxx/qla_gbl.h
index ce32d81..c0c11af 100644
--- a/drivers/scsi/qla2xxx/qla_gbl.h
+++ b/drivers/scsi/qla2xxx/qla_gbl.h
@@ -578,6 +578,7 @@ extern int qla82xx_check_md_needed(scsi_qla_host_t *);
extern void qla82xx_chip_reset_cleanup(scsi_qla_host_t *);
extern int qla82xx_mbx_beacon_ctl(scsi_qla_host_t *, int);
extern char *qdev_state(uint32_t);
+extern void qla82xx_clear_pending_mbx(scsi_qla_host_t *);
/* BSG related functions */
extern int qla24xx_bsg_request(struct fc_bsg_job *);
diff --git a/drivers/scsi/qla2xxx/qla_nx.c b/drivers/scsi/qla2xxx/qla_nx.c
index d025582..9e2c192 100644
--- a/drivers/scsi/qla2xxx/qla_nx.c
+++ b/drivers/scsi/qla2xxx/qla_nx.c
@@ -3817,6 +3817,19 @@ exit:
return rval;
}
+void qla82xx_clear_pending_mbx(scsi_qla_host_t *vha)
+{
+ struct qla_hw_data *ha = vha->hw;
+
+ if (ha->flags.mbox_busy) {
+ ha->flags.mbox_int = 1;
+ ql_log(ql_log_warn, vha, 0x6010,
+ "Doing premature completion of mbx command.\n");
+ if (test_bit(MBX_INTR_WAIT, &ha->mbx_cmd_flags))
+ complete(&ha->mbx_intr_comp);
+ }
+}
+
void qla82xx_watchdog(scsi_qla_host_t *vha)
{
uint32_t dev_state, halt_status;
@@ -3874,16 +3887,8 @@ void qla82xx_watchdog(scsi_qla_host_t *vha)
}
qla2xxx_wake_dpc(vha);
ha->flags.isp82xx_fw_hung = 1;
- if (ha->flags.mbox_busy) {
- ha->flags.mbox_int = 1;
- ql_log(ql_log_warn, vha, 0x6007,
- "Due to FW hung, doing "
- "premature completion of mbx "
- "command.\n");
- if (test_bit(MBX_INTR_WAIT,
- &ha->mbx_cmd_flags))
- complete(&ha->mbx_intr_comp);
- }
+ ql_log(ql_log_warn, vha, 0x6007, "Firmware hung.\n");
+ qla82xx_clear_pending_mbx(vha);
}
}
}
@@ -4078,13 +4083,7 @@ qla82xx_chip_reset_cleanup(scsi_qla_host_t *vha)
msleep(1000);
if (qla82xx_check_fw_alive(vha)) {
ha->flags.isp82xx_fw_hung = 1;
- if (ha->flags.mbox_busy) {
- ha->flags.mbox_int = 1;
- if (test_bit(MBX_INTR_WAIT,
- &ha->mbx_cmd_flags)) {
- complete(&ha->mbx_intr_comp);
- }
- }
+ qla82xx_clear_pending_mbx(vha);
break;
}
}
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 71d6259..f9e5b85 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -4009,16 +4009,8 @@ qla2xxx_pci_error_detected(struct pci_dev *pdev, pci_channel_state_t state)
/* For ISP82XX complete any pending mailbox cmd */
if (IS_QLA82XX(ha)) {
ha->flags.isp82xx_fw_hung = 1;
- if (ha->flags.mbox_busy) {
- ha->flags.mbox_int = 1;
- ql_dbg(ql_dbg_aer, vha, 0x9001,
- "Due to pci channel io frozen, doing premature "
- "completion of mbx command.\n");
- if (test_bit(MBX_INTR_WAIT,
- &ha->mbx_cmd_flags)) {
- complete(&ha->mbx_intr_comp);
- }
- }
+ ql_dbg(ql_dbg_aer, vha, 0x9001, "Pci channel io frozen\n");
+ qla82xx_clear_pending_mbx(vha);
}
qla2x00_free_irqs(vha);
pci_disable_device(pdev);
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 10/14] qla2xxx: Clear mailbox busy flag during premature mailbox completion for ISP82xx.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (8 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 09/14] qla2xxx: Encapsulate prematurely completing mailbox commands during ISP82xx firmware hang Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 11/14] qla2xxx: Disable generating pause frames when firmware hang detected " Chad Dupuis
` (3 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.cim>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_mbx.c | 2 ++
drivers/scsi/qla2xxx/qla_nx.c | 1 +
2 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c
index f965a57..6ff7c3c 100644
--- a/drivers/scsi/qla2xxx/qla_mbx.c
+++ b/drivers/scsi/qla2xxx/qla_mbx.c
@@ -162,6 +162,7 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp)
HINT_MBX_INT_PENDING) {
spin_unlock_irqrestore(&ha->hardware_lock,
flags);
+ ha->flags.mbox_busy = 0;
ql_dbg(ql_dbg_mbx, base_vha, 0x1010,
"Pending mailbox timeout, exiting.\n");
rval = QLA_FUNCTION_TIMEOUT;
@@ -187,6 +188,7 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp)
HINT_MBX_INT_PENDING) {
spin_unlock_irqrestore(&ha->hardware_lock,
flags);
+ ha->flags.mbox_busy = 0;
ql_dbg(ql_dbg_mbx, base_vha, 0x1012,
"Pending mailbox timeout, exiting.\n");
rval = QLA_FUNCTION_TIMEOUT;
diff --git a/drivers/scsi/qla2xxx/qla_nx.c b/drivers/scsi/qla2xxx/qla_nx.c
index 9e2c192..a54f15e 100644
--- a/drivers/scsi/qla2xxx/qla_nx.c
+++ b/drivers/scsi/qla2xxx/qla_nx.c
@@ -3823,6 +3823,7 @@ void qla82xx_clear_pending_mbx(scsi_qla_host_t *vha)
if (ha->flags.mbox_busy) {
ha->flags.mbox_int = 1;
+ ha->flags.mbox_busy = 0;
ql_log(ql_log_warn, vha, 0x6010,
"Doing premature completion of mbx command.\n");
if (test_bit(MBX_INTR_WAIT, &ha->mbx_cmd_flags))
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 11/14] qla2xxx: Disable generating pause frames when firmware hang detected for ISP82xx.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (9 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 10/14] qla2xxx: Clear mailbox busy flag during premature mailbox completion for ISP82xx Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 12/14] qla2xxx: Correct fc_host port_state display Chad Dupuis
` (2 subsequent siblings)
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_dbg.c | 2 +-
drivers/scsi/qla2xxx/qla_mbx.c | 20 ++++++++++++++++++--
drivers/scsi/qla2xxx/qla_nx.c | 6 +++++-
drivers/scsi/qla2xxx/qla_nx.h | 4 ++++
4 files changed, 28 insertions(+), 4 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_dbg.c b/drivers/scsi/qla2xxx/qla_dbg.c
index e320d54..f3cddd5 100644
--- a/drivers/scsi/qla2xxx/qla_dbg.c
+++ b/drivers/scsi/qla2xxx/qla_dbg.c
@@ -12,7 +12,7 @@
* | Level | Last Value Used | Holes |
* ----------------------------------------------------------------------
* | Module Init and Probe | 0x0116 | |
- * | Mailbox commands | 0x1129 | |
+ * | Mailbox commands | 0x112b | |
* | Device Discovery | 0x2083 | |
* | Queue Command and IO tracing | 0x302e | 0x3008 |
* | DPC Thread | 0x401c | |
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c
index 6ff7c3c..82a3353 100644
--- a/drivers/scsi/qla2xxx/qla_mbx.c
+++ b/drivers/scsi/qla2xxx/qla_mbx.c
@@ -303,7 +303,15 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp)
if (!test_bit(ISP_ABORT_NEEDED, &vha->dpc_flags) &&
!test_bit(ABORT_ISP_ACTIVE, &vha->dpc_flags) &&
!test_bit(ISP_ABORT_RETRY, &vha->dpc_flags)) {
-
+ if (IS_QLA82XX(ha)) {
+ ql_dbg(ql_dbg_mbx, vha, 0x112a,
+ "disabling pause transmit on port "
+ "0 & 1.\n");
+ qla82xx_wr_32(ha,
+ QLA82XX_CRB_NIU + 0x98,
+ CRB_NIU_XG_PAUSE_CTL_P0|
+ CRB_NIU_XG_PAUSE_CTL_P1);
+ }
ql_log(ql_log_info, base_vha, 0x101c,
"Mailbox cmd timeout occured. "
"Scheduling ISP abort eeh_busy=0x%x.\n",
@@ -319,7 +327,15 @@ qla2x00_mailbox_command(scsi_qla_host_t *vha, mbx_cmd_t *mcp)
if (!test_bit(ISP_ABORT_NEEDED, &vha->dpc_flags) &&
!test_bit(ABORT_ISP_ACTIVE, &vha->dpc_flags) &&
!test_bit(ISP_ABORT_RETRY, &vha->dpc_flags)) {
-
+ if (IS_QLA82XX(ha)) {
+ ql_dbg(ql_dbg_mbx, vha, 0x112b,
+ "disabling pause transmit on port "
+ "0 & 1.\n");
+ qla82xx_wr_32(ha,
+ QLA82XX_CRB_NIU + 0x98,
+ CRB_NIU_XG_PAUSE_CTL_P0|
+ CRB_NIU_XG_PAUSE_CTL_P1);
+ }
ql_log(ql_log_info, base_vha, 0x101e,
"Mailbox cmd timeout occured. "
"Scheduling ISP abort.\n");
diff --git a/drivers/scsi/qla2xxx/qla_nx.c b/drivers/scsi/qla2xxx/qla_nx.c
index a54f15e..7d1b54f 100644
--- a/drivers/scsi/qla2xxx/qla_nx.c
+++ b/drivers/scsi/qla2xxx/qla_nx.c
@@ -3853,9 +3853,13 @@ void qla82xx_watchdog(scsi_qla_host_t *vha)
qla2xxx_wake_dpc(vha);
} else {
if (qla82xx_check_fw_alive(vha)) {
+ ql_dbg(ql_dbg_timer, vha, 0x6011,
+ "disabling pause transmit on port 0 & 1.\n");
+ qla82xx_wr_32(ha, QLA82XX_CRB_NIU + 0x98,
+ CRB_NIU_XG_PAUSE_CTL_P0|CRB_NIU_XG_PAUSE_CTL_P1);
halt_status = qla82xx_rd_32(ha,
QLA82XX_PEG_HALT_STATUS1);
- ql_dbg(ql_dbg_timer, vha, 0x6005,
+ ql_log(ql_log_info, vha, 0x6005,
"dumping hw/fw registers:.\n "
" PEG_HALT_STATUS1: 0x%x, PEG_HALT_STATUS2: 0x%x,.\n "
" PEG_NET_0_PC: 0x%x, PEG_NET_1_PC: 0x%x,.\n "
diff --git a/drivers/scsi/qla2xxx/qla_nx.h b/drivers/scsi/qla2xxx/qla_nx.h
index 57820c1..57a226b 100644
--- a/drivers/scsi/qla2xxx/qla_nx.h
+++ b/drivers/scsi/qla2xxx/qla_nx.h
@@ -1173,4 +1173,8 @@ struct qla82xx_md_entry_queue {
static const int MD_MIU_TEST_AGT_RDDATA[] = { 0x410000A8, 0x410000AC,
0x410000B8, 0x410000BC };
+
+#define CRB_NIU_XG_PAUSE_CTL_P0 0x1
+#define CRB_NIU_XG_PAUSE_CTL_P1 0x8
+
#endif
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 12/14] qla2xxx: Correct fc_host port_state display.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (10 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 11/14] qla2xxx: Disable generating pause frames when firmware hang detected " Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-12-12 8:50 ` James Bottomley
2011-11-18 17:02 ` [PATCH 13/14] qla2xxx: Submit all chained IOCBs for passthrough commands on request queue 0 Chad Dupuis
2011-11-18 17:02 ` [PATCH 14/14] qla2xxx: Update version number to 8.03.07.12-k Chad Dupuis
13 siblings, 1 reply; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Saurav Kashyap <saurav.kashyap@qlogic.com>
Add more fine grain parsing of vha->loop_state to export a more accurate
fc_host port_state.
Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_attr.c | 27 +++++++++++++++++++++++----
1 files changed, 23 insertions(+), 4 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c
index ac326c4..7acd442 100644
--- a/drivers/scsi/qla2xxx/qla_attr.c
+++ b/drivers/scsi/qla2xxx/qla_attr.c
@@ -1762,12 +1762,31 @@ qla2x00_get_host_port_state(struct Scsi_Host *shost)
scsi_qla_host_t *vha = shost_priv(shost);
struct scsi_qla_host *base_vha = pci_get_drvdata(vha->hw->pdev);
- if (!base_vha->flags.online)
+ if (!base_vha->flags.online) {
fc_host_port_state(shost) = FC_PORTSTATE_OFFLINE;
- else if (atomic_read(&base_vha->loop_state) == LOOP_TIMEOUT)
- fc_host_port_state(shost) = FC_PORTSTATE_UNKNOWN;
- else
+ return;
+ }
+
+ switch (atomic_read(&base_vha->loop_state)) {
+ case LOOP_UPDATE:
+ fc_host_port_state(shost) = FC_PORTSTATE_DIAGNOSTICS;
+ break;
+ case LOOP_DOWN:
+ if(test_bit(LOOP_RESYNC_NEEDED, &base_vha->dpc_flags))
+ fc_host_port_state(shost) = FC_PORTSTATE_DIAGNOSTICS;
+ else
+ fc_host_port_state(shost) = FC_PORTSTATE_LINKDOWN;
+ break;
+ case LOOP_DEAD:
+ fc_host_port_state(shost) = FC_PORTSTATE_LINKDOWN;
+ break;
+ case LOOP_READY:
fc_host_port_state(shost) = FC_PORTSTATE_ONLINE;
+ break;
+ default:
+ fc_host_port_state(shost) = FC_PORTSTATE_UNKNOWN;
+ break;
+ }
}
static int
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* Re: [PATCH 12/14] qla2xxx: Correct fc_host port_state display.
2011-11-18 17:02 ` [PATCH 12/14] qla2xxx: Correct fc_host port_state display Chad Dupuis
@ 2011-12-12 8:50 ` James Bottomley
2011-12-12 19:31 ` Chad Dupuis
0 siblings, 1 reply; 17+ messages in thread
From: James Bottomley @ 2011-12-12 8:50 UTC (permalink / raw)
To: Chad Dupuis; +Cc: giridhar.malavali, andrew.vasquez, linux-scsi
On Fri, 2011-11-18 at 09:02 -0800, Chad Dupuis wrote:
> From: Saurav Kashyap <saurav.kashyap@qlogic.com>
>
> Add more fine grain parsing of vha->loop_state to export a more accurate
> fc_host port_state.
>
> Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
> Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
Could you pass your patches through checkpatch.pl, please? There are 17
errors in here including spaces instead of tabs and a missing space
before the opening bracket of an if clause.
I fixed it up this time.
James
> drivers/scsi/qla2xxx/qla_attr.c | 27 +++++++++++++++++++++++----
> 1 files changed, 23 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c
> index ac326c4..7acd442 100644
> --- a/drivers/scsi/qla2xxx/qla_attr.c
> +++ b/drivers/scsi/qla2xxx/qla_attr.c
> @@ -1762,12 +1762,31 @@ qla2x00_get_host_port_state(struct Scsi_Host *shost)
> scsi_qla_host_t *vha = shost_priv(shost);
> struct scsi_qla_host *base_vha = pci_get_drvdata(vha->hw->pdev);
>
> - if (!base_vha->flags.online)
> + if (!base_vha->flags.online) {
> fc_host_port_state(shost) = FC_PORTSTATE_OFFLINE;
> - else if (atomic_read(&base_vha->loop_state) == LOOP_TIMEOUT)
> - fc_host_port_state(shost) = FC_PORTSTATE_UNKNOWN;
> - else
> + return;
> + }
> +
> + switch (atomic_read(&base_vha->loop_state)) {
> + case LOOP_UPDATE:
> + fc_host_port_state(shost) = FC_PORTSTATE_DIAGNOSTICS;
> + break;
> + case LOOP_DOWN:
> + if(test_bit(LOOP_RESYNC_NEEDED, &base_vha->dpc_flags))
> + fc_host_port_state(shost) = FC_PORTSTATE_DIAGNOSTICS;
> + else
> + fc_host_port_state(shost) = FC_PORTSTATE_LINKDOWN;
> + break;
> + case LOOP_DEAD:
> + fc_host_port_state(shost) = FC_PORTSTATE_LINKDOWN;
> + break;
> + case LOOP_READY:
> fc_host_port_state(shost) = FC_PORTSTATE_ONLINE;
> + break;
> + default:
> + fc_host_port_state(shost) = FC_PORTSTATE_UNKNOWN;
> + break;
> + }
> }
>
> static int
^ permalink raw reply [flat|nested] 17+ messages in thread* Re: [PATCH 12/14] qla2xxx: Correct fc_host port_state display.
2011-12-12 8:50 ` James Bottomley
@ 2011-12-12 19:31 ` Chad Dupuis
0 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-12-12 19:31 UTC (permalink / raw)
To: James Bottomley
Cc: Giridhar Malavali, Andrew Vasquez, linux-scsi@vger.kernel.org
On Mon, 12 Dec 2011, James Bottomley wrote:
> On Fri, 2011-11-18 at 09:02 -0800, Chad Dupuis wrote:
>> From: Saurav Kashyap <saurav.kashyap@qlogic.com>
>>
>> Add more fine grain parsing of vha->loop_state to export a more accurate
>> fc_host port_state.
>>
>> Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
>> Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
>
> Could you pass your patches through checkpatch.pl, please? There are 17
> errors in here including spaces instead of tabs and a missing space
> before the opening bracket of an if clause.
Thanks James. We will be sure to run checkpatch.pl in our future
submissions.
>
> I fixed it up this time.
>
> James
>
>
>> drivers/scsi/qla2xxx/qla_attr.c | 27 +++++++++++++++++++++++----
>> 1 files changed, 23 insertions(+), 4 deletions(-)
>>
>> diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c
>> index ac326c4..7acd442 100644
>> --- a/drivers/scsi/qla2xxx/qla_attr.c
>> +++ b/drivers/scsi/qla2xxx/qla_attr.c
>> @@ -1762,12 +1762,31 @@ qla2x00_get_host_port_state(struct Scsi_Host *shost)
>> scsi_qla_host_t *vha = shost_priv(shost);
>> struct scsi_qla_host *base_vha = pci_get_drvdata(vha->hw->pdev);
>>
>> - if (!base_vha->flags.online)
>> + if (!base_vha->flags.online) {
>> fc_host_port_state(shost) = FC_PORTSTATE_OFFLINE;
>> - else if (atomic_read(&base_vha->loop_state) == LOOP_TIMEOUT)
>> - fc_host_port_state(shost) = FC_PORTSTATE_UNKNOWN;
>> - else
>> + return;
>> + }
>> +
>> + switch (atomic_read(&base_vha->loop_state)) {
>> + case LOOP_UPDATE:
>> + fc_host_port_state(shost) = FC_PORTSTATE_DIAGNOSTICS;
>> + break;
>> + case LOOP_DOWN:
>> + if(test_bit(LOOP_RESYNC_NEEDED, &base_vha->dpc_flags))
>> + fc_host_port_state(shost) = FC_PORTSTATE_DIAGNOSTICS;
>> + else
>> + fc_host_port_state(shost) = FC_PORTSTATE_LINKDOWN;
>> + break;
>> + case LOOP_DEAD:
>> + fc_host_port_state(shost) = FC_PORTSTATE_LINKDOWN;
>> + break;
>> + case LOOP_READY:
>> fc_host_port_state(shost) = FC_PORTSTATE_ONLINE;
>> + break;
>> + default:
>> + fc_host_port_state(shost) = FC_PORTSTATE_UNKNOWN;
>> + break;
>> + }
>> }
>>
>> static int
>
>
>
>
This message and any attached documents contain information from QLogic Corporation or its wholly-owned subsidiaries that may be confidential. If you are not the intended recipient, you may not read, copy, distribute, or use this information. If you have received this transmission in error, please notify the sender immediately by reply e-mail and then delete this message.
^ permalink raw reply [flat|nested] 17+ messages in thread
* [PATCH 13/14] qla2xxx: Submit all chained IOCBs for passthrough commands on request queue 0.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (11 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 12/14] qla2xxx: Correct fc_host port_state display Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
2011-11-18 17:02 ` [PATCH 14/14] qla2xxx: Update version number to 8.03.07.12-k Chad Dupuis
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
From: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_iocb.c | 14 ++++++++------
1 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_iocb.c b/drivers/scsi/qla2xxx/qla_iocb.c
index dbec896..a4b267e 100644
--- a/drivers/scsi/qla2xxx/qla_iocb.c
+++ b/drivers/scsi/qla2xxx/qla_iocb.c
@@ -120,11 +120,10 @@ qla2x00_prep_cont_type0_iocb(struct scsi_qla_host *vha)
* Returns a pointer to the continuation type 1 IOCB packet.
*/
static inline cont_a64_entry_t *
-qla2x00_prep_cont_type1_iocb(scsi_qla_host_t *vha)
+qla2x00_prep_cont_type1_iocb(scsi_qla_host_t *vha, struct req_que *req)
{
cont_a64_entry_t *cont_pkt;
- struct req_que *req = vha->req;
/* Adjust ring index. */
req->ring_index++;
if (req->ring_index == req->length) {
@@ -292,7 +291,7 @@ void qla2x00_build_scsi_iocbs_64(srb_t *sp, cmd_entry_t *cmd_pkt,
* Five DSDs are available in the Continuation
* Type 1 IOCB.
*/
- cont_pkt = qla2x00_prep_cont_type1_iocb(vha);
+ cont_pkt = qla2x00_prep_cont_type1_iocb(vha, vha->req);
cur_dsd = (uint32_t *)cont_pkt->dseg_0_address;
avail_dsds = 5;
}
@@ -684,7 +683,7 @@ qla24xx_build_scsi_iocbs(srb_t *sp, struct cmd_type_7 *cmd_pkt,
* Five DSDs are available in the Continuation
* Type 1 IOCB.
*/
- cont_pkt = qla2x00_prep_cont_type1_iocb(vha);
+ cont_pkt = qla2x00_prep_cont_type1_iocb(vha, vha->req);
cur_dsd = (uint32_t *)cont_pkt->dseg_0_address;
avail_dsds = 5;
}
@@ -2070,7 +2069,8 @@ qla2x00_ct_iocb(srb_t *sp, ms_iocb_entry_t *ct_iocb)
* Five DSDs are available in the Cont.
* Type 1 IOCB.
*/
- cont_pkt = qla2x00_prep_cont_type1_iocb(vha);
+ cont_pkt = qla2x00_prep_cont_type1_iocb(vha,
+ vha->hw->req_q_map[0]);
cur_dsd = (uint32_t *) cont_pkt->dseg_0_address;
avail_dsds = 5;
cont_iocb_prsnt = 1;
@@ -2096,6 +2096,7 @@ qla24xx_ct_iocb(srb_t *sp, struct ct_entry_24xx *ct_iocb)
int index;
uint16_t tot_dsds;
scsi_qla_host_t *vha = sp->fcport->vha;
+ struct qla_hw_data *ha = vha->hw;
struct fc_bsg_job *bsg_job = ((struct srb_ctx *)sp->ctx)->u.bsg_job;
int loop_iterartion = 0;
int cont_iocb_prsnt = 0;
@@ -2141,7 +2142,8 @@ qla24xx_ct_iocb(srb_t *sp, struct ct_entry_24xx *ct_iocb)
* Five DSDs are available in the Cont.
* Type 1 IOCB.
*/
- cont_pkt = qla2x00_prep_cont_type1_iocb(vha);
+ cont_pkt = qla2x00_prep_cont_type1_iocb(vha,
+ ha->req_q_map[0]);
cur_dsd = (uint32_t *) cont_pkt->dseg_0_address;
avail_dsds = 5;
cont_iocb_prsnt = 1;
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 14/14] qla2xxx: Update version number to 8.03.07.12-k.
2011-11-18 17:02 [PATCH 00/14] qla2xxx: Patches for 3.2-rc Chad Dupuis
` (12 preceding siblings ...)
2011-11-18 17:02 ` [PATCH 13/14] qla2xxx: Submit all chained IOCBs for passthrough commands on request queue 0 Chad Dupuis
@ 2011-11-18 17:02 ` Chad Dupuis
13 siblings, 0 replies; 17+ messages in thread
From: Chad Dupuis @ 2011-11-18 17:02 UTC (permalink / raw)
To: jbottomley; +Cc: giridhar.malavali, chad.dupuis, andrew.vasquez, linux-scsi
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
---
drivers/scsi/qla2xxx/qla_version.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_version.h b/drivers/scsi/qla2xxx/qla_version.h
index 13b6357..23f33a6 100644
--- a/drivers/scsi/qla2xxx/qla_version.h
+++ b/drivers/scsi/qla2xxx/qla_version.h
@@ -7,7 +7,7 @@
/*
* Driver version
*/
-#define QLA2XXX_VERSION "8.03.07.07-k"
+#define QLA2XXX_VERSION "8.03.07.12-k"
#define QLA_DRIVER_MAJOR_VER 8
#define QLA_DRIVER_MINOR_VER 3
--
1.6.0.2
^ permalink raw reply related [flat|nested] 17+ messages in thread