diff options
author | Kashyap, Desai <kashyap.desai@lsi.com> | 2010-06-17 03:58:55 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2010-07-27 13:02:06 -0400 |
commit | d274213a1ae59e8abde8d43e1e3a478fe9f28794 (patch) | |
tree | a13dcb559d8a444c862fd57bf0c114dd7425018a /drivers/scsi/mpt2sas/mpt2sas_scsih.c | |
parent | ab6ce92541ea24c6a92be8498d7d1b26c14ec62d (diff) |
[SCSI] mpt2sas: Hold Controller reset when another reset is in progress
Driver should not allow multiple host reset when already host reset is in
progress. It is possible that host reset was sent by scsi mid layer while there was already an host reset active,
either issued via IOCTL interface or internaly, like a config page timeout.
Since there was a host reset active, the driver would return a FAILED response
to the scsi mid layer. The solution is make sure pending host resets will
wait for the active host reset to complete before returning control
back up the call stack.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/mpt2sas/mpt2sas_scsih.c')
-rw-r--r-- | drivers/scsi/mpt2sas/mpt2sas_scsih.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/mpt2sas/mpt2sas_scsih.c b/drivers/scsi/mpt2sas/mpt2sas_scsih.c index 456ea7c3b099..9ce225303938 100644 --- a/drivers/scsi/mpt2sas/mpt2sas_scsih.c +++ b/drivers/scsi/mpt2sas/mpt2sas_scsih.c | |||
@@ -6557,6 +6557,7 @@ _scsih_probe(struct pci_dev *pdev, const struct pci_device_id *id) | |||
6557 | ioc->tm_sas_control_cb_idx = tm_sas_control_cb_idx; | 6557 | ioc->tm_sas_control_cb_idx = tm_sas_control_cb_idx; |
6558 | ioc->logging_level = logging_level; | 6558 | ioc->logging_level = logging_level; |
6559 | /* misc semaphores and spin locks */ | 6559 | /* misc semaphores and spin locks */ |
6560 | mutex_init(&ioc->reset_in_progress_mutex); | ||
6560 | spin_lock_init(&ioc->ioc_reset_in_progress_lock); | 6561 | spin_lock_init(&ioc->ioc_reset_in_progress_lock); |
6561 | spin_lock_init(&ioc->scsi_lookup_lock); | 6562 | spin_lock_init(&ioc->scsi_lookup_lock); |
6562 | spin_lock_init(&ioc->sas_device_lock); | 6563 | spin_lock_init(&ioc->sas_device_lock); |