linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Leave ata_probe_timeout in seconds
@ 2008-07-21 18:30 Matthew Wilcox
  0 siblings, 0 replies; only message in thread
From: Matthew Wilcox @ 2008-07-21 18:30 UTC (permalink / raw)
  To: Jeff Garzik; +Cc: linux-ide


ata_probe_timeout is documented to be in seconds.  It's confusing to
turn it into a count in jiffies in the init routine, then convert it
to milliseconds in the only place in which it is used.  It also makes
/sys/module/libata/parameters/ata_probe_timeout report the wrong value.

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>

diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index 303fc0d..94ab77b 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -1685,7 +1685,7 @@ unsigned ata_exec_internal_sg(struct ata_device *dev,
 	spin_unlock_irqrestore(ap->lock, flags);
 
 	if (!timeout)
-		timeout = ata_probe_timeout * 1000 / HZ;
+		timeout = ata_probe_timeout * 1000;
 
 	rc = wait_for_completion_timeout(&wait, msecs_to_jiffies(timeout));
 
@@ -6073,8 +6073,6 @@ static void __init ata_parse_force_param(void)
 
 static int __init ata_init(void)
 {
-	ata_probe_timeout *= HZ;
-
 	ata_parse_force_param();
 
 	ata_wq = create_workqueue("ata");

-- 
Intel are signing my paycheques ... these opinions are still mine
"Bill, look, we understand that you're interested in selling us this
operating system, but compare it to ours.  We can't possibly take such
a retrograde step."

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

only message in thread, other threads:[~2008-07-21 18:30 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-21 18:30 [PATCH] Leave ata_probe_timeout in seconds Matthew Wilcox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).