aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
authorKashyap, Desai <kashyap.desai@lsi.com>2011-06-14 10:57:08 +0530
committerGreg Kroah-Hartman <gregkh@suse.de>2011-10-03 11:40:48 -0700
commitdb1f8f788b108fa627f011355ff9ba5e3e789fa6 (patch)
treedd4bec3aa178fdc80ab047bf8c83208a500ae7c2 /drivers/scsi
parent68cde1e274f52661b06c0b994c5280e3f880bd74 (diff)
downloadkernel_samsung_smdk4412-db1f8f788b108fa627f011355ff9ba5e3e789fa6.tar.gz
kernel_samsung_smdk4412-db1f8f788b108fa627f011355ff9ba5e3e789fa6.tar.bz2
kernel_samsung_smdk4412-db1f8f788b108fa627f011355ff9ba5e3e789fa6.zip
mpt2sas: Added DID_NO_CONNECT return when driver remove and avoid shutdown call
commit 7821578caa8cb831868989041112ab808029ca65 upstream. Driver should not call shutdown call from _scsih_remove otherwise, The scsi midlayer can be deadlocked when devices are removed from the driver pci_driver->shutdown handler. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/mpt2sas/mpt2sas_scsih.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/scsi/mpt2sas/mpt2sas_scsih.c b/drivers/scsi/mpt2sas/mpt2sas_scsih.c
index e327a3c0360..8dc2ad4a0a3 100644
--- a/drivers/scsi/mpt2sas/mpt2sas_scsih.c
+++ b/drivers/scsi/mpt2sas/mpt2sas_scsih.c
@@ -3698,7 +3698,7 @@ _scsih_qcmd_lck(struct scsi_cmnd *scmd, void (*done)(struct scsi_cmnd *))
return 0;
}
- if (ioc->pci_error_recovery) {
+ if (ioc->pci_error_recovery || ioc->remove_host) {
scmd->result = DID_NO_CONNECT << 16;
scmd->scsi_done(scmd);
return 0;
@@ -7211,7 +7211,6 @@ _scsih_remove(struct pci_dev *pdev)
}
sas_remove_host(shost);
- _scsih_shutdown(pdev);
list_del(&ioc->list);
scsi_remove_host(shost);
scsi_host_put(shost);