linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch.
@ 2012-08-22 11:45 vikas.chaudhary
  2012-08-22 11:45 ` [PATCH 1/4] qla4xxx: Fix lockdep warning in qla4xxx_post_work() vikas.chaudhary
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: vikas.chaudhary @ 2012-08-22 11:45 UTC (permalink / raw)
  To: jbottomley, michaelc
  Cc: linux-scsi, vikas.chaudhary, lalit.chandivade, ravi.anand

From: Vikas Chaudhary <vikas.chaudhary@qlogic.com>

James,

Please apply the following patches to the scsi tree at your earliest
convenience.

Thanks,
Vikas.

Vikas Chaudhary (4):
      qla4xxx: Fix lockdep warning in qla4xxx_post_work()
      qla4xxx: Clear interrupt while unloading driver.
      qla4xxx: Wait for cmd to complete before chip reset for ISP40XX
      qla4xxx: Update driver version to 5.02.00-k20

 drivers/scsi/qla4xxx/ql4_os.c      |   14 ++++++++++++--
 drivers/scsi/qla4xxx/ql4_version.h |    2 +-
 2 files changed, 13 insertions(+), 3 deletions(-)

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH 1/4] qla4xxx: Fix lockdep warning in qla4xxx_post_work()
  2012-08-22 11:45 [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch vikas.chaudhary
@ 2012-08-22 11:45 ` vikas.chaudhary
  2012-08-22 11:45 ` [PATCH 2/4] qla4xxx: Clear interrupt while unloading driver vikas.chaudhary
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: vikas.chaudhary @ 2012-08-22 11:45 UTC (permalink / raw)
  To: jbottomley, michaelc
  Cc: linux-scsi, vikas.chaudhary, lalit.chandivade, ravi.anand

From: Vikas Chaudhary <vikas.chaudhary@qlogic.com>

Fix following lockdep warning:-

 INFO: trying to register non-static key.
 the code is fine but needs lockdep annotation.
 turning off the locking correctness validator.
 Pid: 298, comm: modprobe Not tainted 3.6.0-rc1+ #13
 Call Trace:
 [<c049f5c6>] register_lock_class+0x186/0x360
 [<c06e2e39>] ? __dev_printk+0x139/0x280
 [<c04a288a>] __lock_acquire+0x6a/0x450
 [<c04a2cf4>] lock_acquire+0x84/0xf0
 [<f98bb0d0>] ? qla4xxx_post_work+0x20/0x60 [qla4xxx]
 [<c089a05b>] _raw_spin_lock_irqsave+0x4b/0x60
 [<f98bb0d0>] ? qla4xxx_post_work+0x20/0x60 [qla4xxx]
 [<f98bb0d0>] qla4xxx_post_work+0x20/0x60 [qla4xxx]
 [<f98bb1c9>] qla4xxx_post_aen_work+0x49/0x60 [qla4xxx]
 [<f98c6cf2>] qla4xxx_isr_decode_mailbox+0x3f2/0x780 [qla4xxx]
 [<f98c8493>] qla4_83xx_interrupt_service_routine+0x33/0x50 [qla4xxx]
 [<f98d0e49>] qla4_83xx_process_mbox_intr+0x29/0x40 [qla4xxx]
 [<f98c2031>] qla4xxx_mailbox_command+0x361/0x5d0 [qla4xxx]
 [<c08983c8>] ? mutex_unlock+0x8/0x10
 [<f98c3e86>] qla4xxx_get_ifcb+0x66/0xb0 [qla4xxx]
 [<f98c3ef7>] qla4xxx_update_local_ifcb+0x27/0x100 [qla4xxx]
 [<f98c56af>] qla4xxx_initialize_fw_cb+0x2ff/0x3b0 [qla4xxx]
 [<c04150d0>] ? dma_generic_free_coherent+0x30/0x30
 [<f98c0f70>] qla4xxx_init_firmware+0x40/0xf0 [qla4xxx]
 [<f98c10b6>] qla4xxx_initialize_adapter+0x96/0x120 [qla4xxx]
 [<f98d35cd>] qla4xxx_probe_adapter+0x378/0x855 [qla4xxx]
 [<c04a1a04>] ? trace_hardirqs_on_caller+0xf4/0x180
 [<c04a1a9b>] ? trace_hardirqs_on+0xb/0x10
 [<c06ef403>] ? pm_runtime_enable+0x43/0x70
 [<c062f042>] local_pci_probe+0x42/0xb0
 [<c06300c0>] pci_device_probe+0x60/0x80
 [<c06e6bb6>] really_probe+0x56/0x2e0
 [<c089a5f2>] ? _raw_spin_unlock_irq+0x22/0x30
 [<c06f0b02>] ? pm_runtime_barrier+0x52/0xb0
 [<c06e6e77>] driver_probe_device+0x37/0x90
 [<c0898281>] ? mutex_lock_nested+0x31/0x40
 [<c06e6f51>] __driver_attach+0x81/0x90
 [<c06e51e8>] bus_for_each_dev+0x48/0x70
 [<c06e68e9>] driver_attach+0x19/0x20
 [<c06e6ed0>] ? driver_probe_device+0x90/0x90
 [<c06e637f>] bus_add_driver+0x18f/0x280
 [<c062ff40>] ? pci_dev_put+0x20/0x20
 [<c062ff40>] ? pci_dev_put+0x20/0x20
 [<c06e7435>] driver_register+0x65/0x120
 [<c061a3a2>] ? __raw_spin_lock_init+0x32/0x60
 [<c06302f4>] __pci_register_driver+0x54/0xc0
 [<f98e809e>] qla4xxx_module_init+0x9e/0xcd [qla4xxx]
 [<c040302f>] do_one_initcall+0x2f/0x170
 [<f98e8000>] ? 0xf98e7fff
 [<c04ae025>] sys_init_module+0x75/0x1c0
 [<c04a1a04>] ? trace_hardirqs_on_caller+0xf4/0x180
 [<c0609514>] ? trace_hardirqs_on_thunk+0xc/0x10
 [<c08a141f>] sysenter_do_call+0x12/0x38

Signed-off-by: Vikas Chaudhary <vikas.chaudhary@qlogic.com>
---
 drivers/scsi/qla4xxx/ql4_os.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c
index 9c3442d..fa1a359 100644
--- a/drivers/scsi/qla4xxx/ql4_os.c
+++ b/drivers/scsi/qla4xxx/ql4_os.c
@@ -5104,6 +5104,7 @@ static int __devinit qla4xxx_probe_adapter(struct pci_dev *pdev,
 	init_completion(&ha->disable_acb_comp);
 
 	spin_lock_init(&ha->hardware_lock);
+	spin_lock_init(&ha->work_lock);
 
 	/* Initialize work list */
 	INIT_LIST_HEAD(&ha->work_list);
-- 
1.7.8.GIT


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/4] qla4xxx: Clear interrupt while unloading driver.
  2012-08-22 11:45 [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch vikas.chaudhary
  2012-08-22 11:45 ` [PATCH 1/4] qla4xxx: Fix lockdep warning in qla4xxx_post_work() vikas.chaudhary
@ 2012-08-22 11:45 ` vikas.chaudhary
  2012-08-22 11:45 ` [PATCH 3/4] qla4xxx: Wait for cmd to complete before chip reset for ISP40XX vikas.chaudhary
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: vikas.chaudhary @ 2012-08-22 11:45 UTC (permalink / raw)
  To: jbottomley, michaelc
  Cc: linux-scsi, vikas.chaudhary, lalit.chandivade, ravi.anand

From: Vikas Chaudhary <vikas.chaudhary@qlogic.com>

while processing the stop firmware mailbox command on driver unload,
a interrupt is processed which causes kernel panic as the response
queue is not valid.

Fix is to clear the interrupt in free_adapter call just after
disabling the interrupts.

Signed-off-by: Vikas Chaudhary <vikas.chaudhary@qlogic.com>
---
 drivers/scsi/qla4xxx/ql4_os.c |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c
index fa1a359..f06b7c5 100644
--- a/drivers/scsi/qla4xxx/ql4_os.c
+++ b/drivers/scsi/qla4xxx/ql4_os.c
@@ -3487,6 +3487,15 @@ static void qla4xxx_free_adapter(struct scsi_qla_host *ha)
 		ha->isp_ops->disable_intrs(ha);
 	}
 
+	if (is_qla40XX(ha)) {
+		writel(set_rmask(CSR_SCSI_PROCESSOR_INTR),
+		       &ha->reg->ctrl_status);
+		readl(&ha->reg->ctrl_status);
+	} else if (is_qla8022(ha)) {
+		writel(0, &ha->qla4_8xxx_reg->host_int);
+		readl(&ha->qla4_8xxx_reg->host_int);
+	}
+
 	/* Remove timer thread, if present */
 	if (ha->timer_active)
 		qla4xxx_stop_timer(ha);
-- 
1.7.8.GIT


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 3/4] qla4xxx: Wait for cmd to complete before chip reset for ISP40XX
  2012-08-22 11:45 [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch vikas.chaudhary
  2012-08-22 11:45 ` [PATCH 1/4] qla4xxx: Fix lockdep warning in qla4xxx_post_work() vikas.chaudhary
  2012-08-22 11:45 ` [PATCH 2/4] qla4xxx: Clear interrupt while unloading driver vikas.chaudhary
@ 2012-08-22 11:45 ` vikas.chaudhary
  2012-08-22 11:45 ` [PATCH 4/4] qla4xxx: Update driver version to 5.02.00-k20 vikas.chaudhary
  2012-09-06  5:36 ` [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch Mike Christie
  4 siblings, 0 replies; 6+ messages in thread
From: vikas.chaudhary @ 2012-08-22 11:45 UTC (permalink / raw)
  To: jbottomley, michaelc
  Cc: linux-scsi, vikas.chaudhary, lalit.chandivade, ravi.anand

From: Vikas Chaudhary <vikas.chaudhary@qlogic.com>

Signed-off-by: Vikas Chaudhary <vikas.chaudhary@qlogic.com>
---
 drivers/scsi/qla4xxx/ql4_os.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c
index f06b7c5..0a0c9c5 100644
--- a/drivers/scsi/qla4xxx/ql4_os.c
+++ b/drivers/scsi/qla4xxx/ql4_os.c
@@ -3000,10 +3000,10 @@ static int qla4xxx_recover_adapter(struct scsi_qla_host *ha)
 			set_current_state(TASK_UNINTERRUPTIBLE);
 			schedule_timeout(HZ);
 		}
-
+chip_reset:
 		if (!test_bit(AF_FW_RECOVERY, &ha->flags))
 			qla4xxx_cmd_wait(ha);
-chip_reset:
+
 		qla4xxx_process_aen(ha, FLUSH_DDB_CHANGED_AENS);
 		qla4xxx_abort_active_cmds(ha, DID_RESET << 16);
 		DEBUG2(ql4_printk(KERN_INFO, ha,
-- 
1.7.8.GIT


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 4/4] qla4xxx: Update driver version to 5.02.00-k20
  2012-08-22 11:45 [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch vikas.chaudhary
                   ` (2 preceding siblings ...)
  2012-08-22 11:45 ` [PATCH 3/4] qla4xxx: Wait for cmd to complete before chip reset for ISP40XX vikas.chaudhary
@ 2012-08-22 11:45 ` vikas.chaudhary
  2012-09-06  5:36 ` [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch Mike Christie
  4 siblings, 0 replies; 6+ messages in thread
From: vikas.chaudhary @ 2012-08-22 11:45 UTC (permalink / raw)
  To: jbottomley, michaelc
  Cc: linux-scsi, vikas.chaudhary, lalit.chandivade, ravi.anand

From: Vikas Chaudhary <vikas.chaudhary@qlogic.com>

Signed-off-by: Vikas Chaudhary <vikas.chaudhary@qlogic.com>
---
 drivers/scsi/qla4xxx/ql4_version.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/qla4xxx/ql4_version.h b/drivers/scsi/qla4xxx/ql4_version.h
index 04b2f5b..715e1ff 100644
--- a/drivers/scsi/qla4xxx/ql4_version.h
+++ b/drivers/scsi/qla4xxx/ql4_version.h
@@ -5,4 +5,4 @@
  * See LICENSE.qla4xxx for copyright and licensing details.
  */
 
-#define QLA4XXX_DRIVER_VERSION	"5.02.00-k19"
+#define QLA4XXX_DRIVER_VERSION	"5.02.00-k20"
-- 
1.7.8.GIT


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch.
  2012-08-22 11:45 [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch vikas.chaudhary
                   ` (3 preceding siblings ...)
  2012-08-22 11:45 ` [PATCH 4/4] qla4xxx: Update driver version to 5.02.00-k20 vikas.chaudhary
@ 2012-09-06  5:36 ` Mike Christie
  4 siblings, 0 replies; 6+ messages in thread
From: Mike Christie @ 2012-09-06  5:36 UTC (permalink / raw)
  To: vikas.chaudhary; +Cc: jbottomley, linux-scsi, lalit.chandivade, ravi.anand

On 08/22/2012 06:45 AM, vikas.chaudhary@qlogic.com wrote:
> From: Vikas Chaudhary <vikas.chaudhary@qlogic.com>
> 
> James,
> 
> Please apply the following patches to the scsi tree at your earliest
> convenience.
> 
> Thanks,
> Vikas.
> 
> Vikas Chaudhary (4):
>       qla4xxx: Fix lockdep warning in qla4xxx_post_work()
>       qla4xxx: Clear interrupt while unloading driver.
>       qla4xxx: Wait for cmd to complete before chip reset for ISP40XX
>       qla4xxx: Update driver version to 5.02.00-k20
> 

Looks ok to me.

Reviewed-by: Mike Christie <michaelc@cs.wisc.edu>


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-09-06  5:36 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-22 11:45 [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch vikas.chaudhary
2012-08-22 11:45 ` [PATCH 1/4] qla4xxx: Fix lockdep warning in qla4xxx_post_work() vikas.chaudhary
2012-08-22 11:45 ` [PATCH 2/4] qla4xxx: Clear interrupt while unloading driver vikas.chaudhary
2012-08-22 11:45 ` [PATCH 3/4] qla4xxx: Wait for cmd to complete before chip reset for ISP40XX vikas.chaudhary
2012-08-22 11:45 ` [PATCH 4/4] qla4xxx: Update driver version to 5.02.00-k20 vikas.chaudhary
2012-09-06  5:36 ` [PATCH 0/4] qla4xxx: Updates for scsi "misc" branch Mike Christie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).