public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 08/09] [SCSI] mpt2sas : Fix for With post diag reset same set of device gets added, removed and then again gets added with new target ids
@ 2012-07-17 10:26 sreekanth.reddy
  0 siblings, 0 replies; only message in thread
From: sreekanth.reddy @ 2012-07-17 10:26 UTC (permalink / raw)
  To: linux-scsi, Sathya.Prakash, Nagalakshmi.Nandigama,
	sreekanth.reddy; +Cc: jejb

When device discovery is disabled during driver load time using module parameter
"disable_discovery=1" and when diag reset is issued then from logs, it is observed
that the devices get added, removed and then added with new target ids.

So, inorder to limit this turn-off the code which is deleting and devices across
host reset when the disable_discovery module parameter is turned on.

Signed-off-by: Sreekanth Reddy <sreekanth.reddy@lsi.com>
---

diff --git a/drivers/scsi/mpt2sas/mpt2sas_scsih.c b/drivers/scsi/mpt2sas/mpt2sas_scsih.c
index 7a69a5c..7efefb7 100644
--- a/drivers/scsi/mpt2sas/mpt2sas_scsih.c
+++ b/drivers/scsi/mpt2sas/mpt2sas_scsih.c
@@ -7264,7 +7264,8 @@ mpt2sas_scsih_reset_handler(struct MPT2SAS_ADAPTER *ioc, int reset_phase)
 		_scsih_search_responding_sas_devices(ioc);
 		_scsih_search_responding_raid_devices(ioc);
 		_scsih_search_responding_expanders(ioc);
-		if (!ioc->is_driver_loading) {
+		if ((!ioc->is_driver_loading) && !(disable_discovery > 0 &&
+		    !ioc->sas_hba.num_phys)) {
 			_scsih_prep_device_scan(ioc);
 			_scsih_search_responding_sas_devices(ioc);
 			_scsih_search_responding_raid_devices(ioc);

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-07-17 10:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-17 10:26 [PATCH 08/09] [SCSI] mpt2sas : Fix for With post diag reset same set of device gets added, removed and then again gets added with new target ids sreekanth.reddy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox