Subject: Re: ATA/ATAPI kernel redesign
To: None <tech-kern@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: tech-kern
Date: 02/23/2002 20:45:10
> This raises another point.  We don't wait for 30s after a reset,

There's code there that tries to.

What it doesn't do is wait for (up to) 30s during first probe, in case
wdcprobe is called sooner than 30s after a hardware reset during the
boot sequence.  I discovered this the hard way when working on making
the wd driver "just work" for Chuck Dickman's Qbus IDE board; since I
wanted to use wdc.c and everything under it untouched, I had to make
the "wdc at uba" glue poll waiting for reset to complete.  (Before the
VAX people start asking where the code is, wdc at uba doesn't work yet.
It appears to work for 512-byte transfers, but it goes wonky for
1024-byte transfers and breaks catastrophically for 1536-byte or
2048-byte (and presumably larger) transfers.  I don't (yet) have any
idea why.)

As for suppressing gratuitous resets, have a look at
WDC_CAPABILITY_NO_EXTRA_RESETS.  (Unless that's been ripped out since
the version I've been working with....)

/~\ The ASCII				der Mouse
\ / Ribbon Campaign
 X  Against HTML	       mouse@rodents.montreal.qc.ca
/ \ Email!	     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B