linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Timeout at bootTime with NEC3500A (and others) when inserted a CD in it.
@ 2005-04-26 14:19 Marcello Maggioni
  2005-04-28 21:56 ` Marcello Maggioni
  0 siblings, 1 reply; 2+ messages in thread
From: Marcello Maggioni @ 2005-04-26 14:19 UTC (permalink / raw)
  To: linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1579 bytes --]

Hi all, 

I've attached a patch intended for solving boottime issues with this
and other drives when a CD/DVD is inserted .

Problem: Some drives (NEC 3500 , TDK 1616N , Mad-dog MD-16XDVD9, RICOH
MP5163DA , Memorex DVD9 drive and IO-DATA's too for sure) , if a
CD/DVD is inserted into the tray when the system is booted and if
before the OS bootup the BIOS checked for the presence of a bootable
CD/DVD into the drive , during the IDE probe phase the drive may
result busy and remain so for the next 25/30 seconds . This cause the
drive to be skipped during the booting phase and not begin usable
until the next reboot (if the reboot goes well and the drive doesn't
timeout again ).

Solution: Rising the timeout time from 10 seconds to 35 seconds
(during these 35 seconds  every drive should wake up for sure
according to the tests I've done) .


Here the simple patch :

--- drivers/ide/ide-probe.c.orig	2005-04-26 15:04:46.000000000 +0200
+++ drivers/ide/ide-probe.c	2005-04-26 15:04:14.000000000 +0200
@@ -638,13 +638,13 @@
 	SELECT_DRIVE(&hwif->drives[0]);
 	hwif->OUTB(8, hwif->io_ports[IDE_CONTROL_OFFSET]);
 	mdelay(2);
-	rc = ide_wait_not_busy(hwif, 10000);
+	rc = ide_wait_not_busy(hwif, 35000);
 	if (rc)
 		return rc;
 	SELECT_DRIVE(&hwif->drives[1]);
 	hwif->OUTB(8, hwif->io_ports[IDE_CONTROL_OFFSET]);
 	mdelay(2);
-	rc = ide_wait_not_busy(hwif, 10000);
+	rc = ide_wait_not_busy(hwif, 35000);
 
 	/* Exit function with master reselected (let's be sane) */
 	SELECT_DRIVE(&hwif->drives[0]);


Greets,

Maggioni Marcello

[-- Attachment #2: ide-timeout-NEC3500.diff --]
[-- Type: text/plain, Size: 632 bytes --]

--- drivers/ide/ide-probe.c.orig	2005-04-26 15:04:46.000000000 +0200
+++ drivers/ide/ide-probe.c	2005-04-26 15:04:14.000000000 +0200
@@ -638,13 +638,13 @@
 	SELECT_DRIVE(&hwif->drives[0]);
 	hwif->OUTB(8, hwif->io_ports[IDE_CONTROL_OFFSET]);
 	mdelay(2);
-	rc = ide_wait_not_busy(hwif, 10000);
+	rc = ide_wait_not_busy(hwif, 35000);
 	if (rc)
 		return rc;
 	SELECT_DRIVE(&hwif->drives[1]);
 	hwif->OUTB(8, hwif->io_ports[IDE_CONTROL_OFFSET]);
 	mdelay(2);
-	rc = ide_wait_not_busy(hwif, 10000);
+	rc = ide_wait_not_busy(hwif, 35000);
 
 	/* Exit function with master reselected (let's be sane) */
 	SELECT_DRIVE(&hwif->drives[0]);

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

* Re: [PATCH] Timeout at bootTime with NEC3500A (and others) when inserted a CD in it.
  2005-04-26 14:19 [PATCH] Timeout at bootTime with NEC3500A (and others) when inserted a CD in it Marcello Maggioni
@ 2005-04-28 21:56 ` Marcello Maggioni
  0 siblings, 0 replies; 2+ messages in thread
From: Marcello Maggioni @ 2005-04-28 21:56 UTC (permalink / raw)
  To: linux-kernel, linux-ide

2005/4/26, Marcello Maggioni <hayarms@gmail.com>:
> Hi all,
> 
> I've attached a patch intended for solving boottime issues with this
> and other drives when a CD/DVD is inserted .
> 
> Problem: Some drives (NEC 3500 , TDK 1616N , Mad-dog MD-16XDVD9, RICOH
> MP5163DA , Memorex DVD9 drive and IO-DATA's too for sure) , if a
> CD/DVD is inserted into the tray when the system is booted and if
> before the OS bootup the BIOS checked for the presence of a bootable
> CD/DVD into the drive , during the IDE probe phase the drive may
> result busy and remain so for the next 25/30 seconds . This cause the
> drive to be skipped during the booting phase and not begin usable
> until the next reboot (if the reboot goes well and the drive doesn't
> timeout again ).
> 
> Solution: Rising the timeout time from 10 seconds to 35 seconds
> (during these 35 seconds  every drive should wake up for sure
> according to the tests I've done) .
> 
> Here the simple patch :
> 
> --- drivers/ide/ide-probe.c.orig        2005-04-26 15:04:46.000000000 +0200
> +++ drivers/ide/ide-probe.c     2005-04-26 15:04:14.000000000 +0200
> @@ -638,13 +638,13 @@
>         SELECT_DRIVE(&hwif->drives[0]);
>         hwif->OUTB(8, hwif->io_ports[IDE_CONTROL_OFFSET]);
>         mdelay(2);
> -       rc = ide_wait_not_busy(hwif, 10000);
> +       rc = ide_wait_not_busy(hwif, 35000);
>         if (rc)
>                 return rc;
>         SELECT_DRIVE(&hwif->drives[1]);
>         hwif->OUTB(8, hwif->io_ports[IDE_CONTROL_OFFSET]);
>         mdelay(2);
> -       rc = ide_wait_not_busy(hwif, 10000);
> +       rc = ide_wait_not_busy(hwif, 35000);
> 
>         /* Exit function with master reselected (let's be sane) */
>         SELECT_DRIVE(&hwif->drives[0]);
> 
> Greets,
> 
> Maggioni Marcello
> 

I have a question to ask.

What would be the negative effect of rising this timeout time?

Thanks

Bye

Marcello

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

end of thread, other threads:[~2005-04-28 21:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-04-26 14:19 [PATCH] Timeout at bootTime with NEC3500A (and others) when inserted a CD in it Marcello Maggioni
2005-04-28 21:56 ` Marcello Maggioni

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).