aboutsummaryrefslogtreecommitdiff
path: root/drivers/scsi
diff options
context:
space:
mode:
authorSalyzyn, Mark <mark_salyzyn@adaptec.com>2007-05-30 11:59:13 -0400
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2007-06-01 11:42:19 -0400
commit94774a3a8e01989960aaadaea6deff51a4e7deed (patch)
tree7b482d61cec03edf5852f3b005e319ee61b2d46a /drivers/scsi
parent88f5774b0748d6d9ebec7a39caae98c0d83b8cc8 (diff)
[SCSI] aacraid: fix shutdown handler to also disable interrupts.
Moves quiesce, thread and interrupt shutdown into aacraid drivers' .shutdown handler. This fix to the aac_shutdown handler will remove the superfluous reset of the adapter during a (clean) kexec. This fix may mitigate the active investigation 'kexec and aacraid broken' but it is unlikely to affect the root cause (issue likely present in both kexec and kdump). This patch reduces the chance the problem will occur with a kexec. The fix for root cause is currently expected to be the minimum value check to the aacraid.startup_timeout driver variable after an adapter reset within aacraid_commit_reset.patch submitted on 05/22/2007 and awaiting testing by Yinghai to confirm. Signed-off-by: Mark Salyzyn <aacraid@adaptec.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/aacraid/linit.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/drivers/scsi/aacraid/linit.c b/drivers/scsi/aacraid/linit.c
index 350ea7feb61..5c487ff096c 100644
--- a/drivers/scsi/aacraid/linit.c
+++ b/drivers/scsi/aacraid/linit.c
@@ -863,6 +863,14 @@ static struct scsi_host_template aac_driver_template = {
.emulated = 1,
};
+static void __aac_shutdown(struct aac_dev * aac)
+{
+ kthread_stop(aac->thread);
+ aac_send_shutdown(aac);
+ aac_adapter_disable_int(aac);
+ free_irq(aac->pdev->irq, aac);
+}
+
static int __devinit aac_probe_one(struct pci_dev *pdev,
const struct pci_device_id *id)
{
@@ -1015,10 +1023,7 @@ static int __devinit aac_probe_one(struct pci_dev *pdev,
return 0;
out_deinit:
- kthread_stop(aac->thread);
- aac_send_shutdown(aac);
- aac_adapter_disable_int(aac);
- free_irq(pdev->irq, aac);
+ __aac_shutdown(aac);
out_unmap:
aac_fib_map_free(aac);
pci_free_consistent(aac->pdev, aac->comm_size, aac->comm_addr, aac->comm_phys);
@@ -1038,7 +1043,8 @@ static void aac_shutdown(struct pci_dev *dev)
{
struct Scsi_Host *shost = pci_get_drvdata(dev);
struct aac_dev *aac = (struct aac_dev *)shost->hostdata;
- aac_send_shutdown(aac);
+ scsi_block_requests(shost);
+ __aac_shutdown(aac);
}
static void __devexit aac_remove_one(struct pci_dev *pdev)
@@ -1048,16 +1054,12 @@ static void __devexit aac_remove_one(struct pci_dev *pdev)
scsi_remove_host(shost);
- kthread_stop(aac->thread);
-
- aac_send_shutdown(aac);
- aac_adapter_disable_int(aac);
+ __aac_shutdown(aac);
aac_fib_map_free(aac);
pci_free_consistent(aac->pdev, aac->comm_size, aac->comm_addr,
aac->comm_phys);
kfree(aac->queues);
- free_irq(pdev->irq, aac);
aac_adapter_ioremap(aac, 0);
kfree(aac->fibs);