Subject: Re: wdc0: lost interupt: status 59 error 40
To: Eric S. Hvozda <hvozda@netcom.com>
From: Brett Lymn <blymn@awadi.com.AU>
List: tech-kern
Date: 09/22/1995 17:10:48
According to Eric S. Hvozda:
>
>On Tue, 19 Sep 95 14:17:11 -0700  "Eric S. Hvozda" wrote:
>> After trying a netbsd-current kernel with WDDEBUG turned on, now I see
>> the following only when /usr is mounted.  It usually takes a while for
>> it to appear, when it does; it spells certian death (ie the machine
>> locks):
>> 
>> wdc0: lost interupt: status 58<rdy,seekdone,drq> error 0
>> wdc0: lost interupt: status 59<rdy,seekdone,drq,err> error 40<uncorr>
>> wdc0: lost interupt: status 59<rdy,seekdone,drq,err> error 40<uncorr>
>> wdc0: lost interupt: status 59<rdy,seekdone,drq,err> error 40<uncorr>
>> [...]
>

Yeah, I had a similar problem trying to read a stuffed hard disk
('cept somebody desperately wanted the data in this case).  

>
>My question is why didn't wdc0 report the bad head & cylinder...?
>

Actually, because the driver does not recover from the error - the
error count is not incremented past 1 when the command is retried so
it just keeps retrying until you reach for the reset.  I have done a
fix for this, one where the number of lost interrupts is counted and
an error flagged.  When the error is flagged the usual info will be
printed out.  Dunno if that is the right way to go about it.  I can
provide a patch to 1.0 wd.c if anyone wants it.....

If Charles is out there.... Do you want the fix?

-- 
Brett Lymn, Computer Systems Administrator, AWA Defence Industries
===============================================================================
"It's fifteen hundred miles to Ankh-Morpork" he said.  "We've got
three hundred and sixty three elephants, fifty carts of forage, the
monsoon's about to break and we're wearing ... we're wearing ... sort
of things, like glass, only dark... dark glass things on our eyes..."
        - Terry Pratchett "Moving Pictures".