Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 2 Dec 1997 12:13:54 -0600 (CST)
From:      "Daniel M. Eischen" <deischen@iworks.interworks.org>
To:        freebsd-hackers@freebsd.org, freebsd-mobile@freebsd.org
Subject:   Fix for slow reacting ATAPI CD-ROM
Message-ID:  <199712021813.MAA10260@iworks.InterWorks.org>

next in thread | raw e-mail | index | archive | help

Please forgive the cross-post, wasn't sure where this belongs.  

I have a new ChemUSA Chembook and everything works fine
except for the CD-ROM drive, which times out waiting 
for the command phase in atapi_wait_cmd().  I was able
to get it to work by increasing the wait count to 3000.

        /* Wait for DRQ from 50 usec to 3 msec for slow devices */
        int cnt = ata->intrcmd ? 10000 : ata->slow ? 3000 : 50;
        int ireason = 0, phase = 0;

+       cnt = 3000;
+ 
	/* Wait for command phase. */
	for (; cnt>0; cnt-=10) {
		ireason = inb (ata->port + AR_IREASON);

Obviously, this drive isn't detected as a slow device (I
can post the boot messages later if needed).  What I wanted
to do was to add a config flag for setting this, but it doesn't
look like that is sent down to the atapi driver.

Question: Can we change atapi_attach() to accept a 4th argument
          and use this to pass config flags from wdattach() in
          wd.c?  Is there another method I should be using to
          handle atapi device quirks?

Thanks,

Dan Eischen
deischen@iworks.InterWorks.org



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199712021813.MAA10260>