All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/1] scsi: scsi inquiry timeout config option
@ 2005-10-03 20:26 brking
  2005-10-03 20:39 ` linas
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: brking @ 2005-10-03 20:26 UTC (permalink / raw)
  To: James.Bottomley; +Cc: linux-scsi, linuxppc64-dev, brking


Add a .config option to default the scsi scan inquiry timeout.
Due to a broken device (SCSI/ATA converter card) that is very
common on IBM iSeries/pSeries machines, these architectures
need a longer default inquiry timeout.

Signed-off-by: Brian King <brking@us.ibm.com>
---

 linux-2.6-bjking1/arch/ppc64/configs/iSeries_defconfig |    1 +
 linux-2.6-bjking1/arch/ppc64/configs/pSeries_defconfig |    1 +
 linux-2.6-bjking1/drivers/scsi/Kconfig                 |    8 ++++++++
 linux-2.6-bjking1/drivers/scsi/scsi_scan.c             |    2 +-
 4 files changed, 11 insertions(+), 1 deletion(-)

diff -puN drivers/scsi/Kconfig~scsi_inq_timeout_config drivers/scsi/Kconfig
--- linux-2.6/drivers/scsi/Kconfig~scsi_inq_timeout_config	2005-10-03 11:15:08.000000000 -0500
+++ linux-2.6-bjking1/drivers/scsi/Kconfig	2005-10-03 11:17:37.000000000 -0500
@@ -209,6 +209,14 @@ config SCSI_LOGGING
 	  there should be no noticeable performance impact as long as you have
 	  logging turned off.
 
+config SCSI_INQUIRY_TIMEOUT
+	int "default timeout in seconds for INQUIRY scan"
+	depends on SCSI
+	default "5"
+	---help---
+	  Timeout (in seconds) waiting for devices to answer INQUIRY.
+	  Default is 5. Some non-compliant devices need more.
+
 menu "SCSI Transport Attributes"
 	depends on SCSI
 
diff -puN drivers/scsi/scsi_scan.c~scsi_inq_timeout_config drivers/scsi/scsi_scan.c
--- linux-2.6/drivers/scsi/scsi_scan.c~scsi_inq_timeout_config	2005-10-03 11:17:44.000000000 -0500
+++ linux-2.6-bjking1/drivers/scsi/scsi_scan.c	2005-10-03 11:18:58.000000000 -0500
@@ -102,7 +102,7 @@ MODULE_PARM_DESC(max_report_luns,
 		 "REPORT LUNS maximum number of LUNS received (should be"
 		 " between 1 and 16384)");
 
-static unsigned int scsi_inq_timeout = SCSI_TIMEOUT/HZ+3;
+static unsigned int scsi_inq_timeout = CONFIG_SCSI_INQUIRY_TIMEOUT;
 
 module_param_named(inq_timeout, scsi_inq_timeout, int, S_IRUGO|S_IWUSR);
 MODULE_PARM_DESC(inq_timeout, 
diff -puN arch/ppc64/configs/pSeries_defconfig~scsi_inq_timeout_config arch/ppc64/configs/pSeries_defconfig
--- linux-2.6/arch/ppc64/configs/pSeries_defconfig~scsi_inq_timeout_config	2005-10-03 11:19:18.000000000 -0500
+++ linux-2.6-bjking1/arch/ppc64/configs/pSeries_defconfig	2005-10-03 11:21:18.000000000 -0500
@@ -436,6 +436,7 @@ CONFIG_CHR_DEV_SG=y
 CONFIG_SCSI_MULTI_LUN=y
 CONFIG_SCSI_CONSTANTS=y
 # CONFIG_SCSI_LOGGING is not set
+CONFIG_SCSI_INQUIRY_TIMEOUT=30
 
 #
 # SCSI Transport Attributes
diff -puN arch/ppc64/configs/iSeries_defconfig~scsi_inq_timeout_config arch/ppc64/configs/iSeries_defconfig
--- linux-2.6/arch/ppc64/configs/iSeries_defconfig~scsi_inq_timeout_config	2005-10-03 11:24:14.000000000 -0500
+++ linux-2.6-bjking1/arch/ppc64/configs/iSeries_defconfig	2005-10-03 11:24:29.000000000 -0500
@@ -343,6 +343,7 @@ CONFIG_CHR_DEV_SG=y
 CONFIG_SCSI_MULTI_LUN=y
 CONFIG_SCSI_CONSTANTS=y
 # CONFIG_SCSI_LOGGING is not set
+CONFIG_SCSI_INQUIRY_TIMEOUT=30
 
 #
 # SCSI Transport Attributes
_

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

end of thread, other threads:[~2005-10-04 18:46 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-10-03 20:26 [PATCH 1/1] scsi: scsi inquiry timeout config option brking
2005-10-03 20:39 ` linas
2005-10-03 20:44   ` Brian King
2005-10-03 21:01 ` James Bottomley
2005-10-03 21:31   ` Brian King
2005-10-03 21:34     ` Randy.Dunlap
2005-10-03 21:42       ` Brian King
2005-10-03 21:47         ` Randy.Dunlap
2005-10-04 18:46 ` Christoph Hellwig

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.