Subject: FIX for: Problem with wd driver and Seagate drives (was: Re: NetBSD 3.0_BETA & RAIDframe problems)
To: None <teemu@rinta-aho.org, netbsd-help@netbsd.org,>
From: Dieter <netbsd@sopwith.solgatos.com>
List: netbsd-help
Date: 06/15/2005 13:09:38
------- Forwarded Message
> >>> I bought two 200GB Seagate Barracuda 7200.7 SATA discs
>
> >>> piixide1: Intel 82801EB Serial ATA Controller (rev. 0x02)
>
> >> (The above sector is at the 128GB mark on the disk... I wonder if
> >> there is something special about that?
>
> > Its a seagate disk isn't it? Some seagate disks can only access
> > the last 'pre LBA48' sector via LBA48. There is a quirk table
> > in NetBSD, but really NetBSD should try LBA48 on that sector
> > if non LBA48 fails.
>
> Seagate 7200.8 250 GB SATA connected to a
> satalink0: Silicon Image SATALink 3512 (rev. 0x01)
> Alpha 164lx running NetBSD 2.0.2
>
> sopwith # dd if=/dev/rwd0c of=/dev/null bs=512 skip=268435000 count=10000
> dd: /dev/rwd0c: Input/output error
> 455+0 records in
> 455+0 records out
> 232960 bytes transferred in 3.730 secs (62455 bytes/sec)
> sopwith # dd if=/dev/rwd0c of=/dev/null bs=512 skip=268435455 count=1
> dd: /dev/rwd0c: Input/output error
> 0+0 records in
> 0+0 records out
> 0 bytes transferred in 3.536 secs (0 bytes/sec)
> sopwith # dd if=/dev/rwd0c of=/dev/null bs=512 skip=268435456 count=100
> 100+0 records in
> 100+0 records out
> 51200 bytes transferred in 0.057 secs (898245 bytes/sec)
> sopwith #
>
>
> wd0c: error reading fsbn 268435455 (wd0 bn 268435455; cn 266305 tn 0 sn 15), retrying
> wd0: (id not found)
> wd0c: error reading fsbn 268435455 (wd0 bn 268435455; cn 266305 tn 0 sn 15), retrying
> wd0: (id not found)
> wd0c: error reading fsbn 268435455 (wd0 bn 268435455; cn 266305 tn 0 sn 15), retrying
> wd0: (id not found)
> wd0: transfer error, downgrading to Ultra-DMA mode 2
> wd0(satalink0:1:0): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA data transfers)
> wd0c: error reading fsbn 268435455 (wd0 bn 268435455; cn 266305 tn 0 sn 15), retrying
> wd0: (id not found)
> wd0c: error reading fsbn 268435455 (wd0 bn 268435455; cn 266305 tn 0 sn 15), retrying
> wd0: (id not found)
> wd0c: error reading fsbn 268435455 (wd0 bn 268435455; cn 266305 tn 0 sn 15)wd0: (id not found)
>
------- End of Forwarded Message
This one is so easy, even I can fix it. :-)
Teemu, try the fix and see if it works for your disks.
I included the string for your disks.
It worked for mine.
What we need is a complete list of drives that need this,
or a more general fix.
===================================================================
RCS file: dev/ata/RCS/wd.c,v
retrieving revision 1.1
diff -c10 -r1.1 dev/ata/wd.c
*** dev/ata/wd.c 2005/06/15 19:39:09 1.1
--- dev/ata/wd.c 2005/06/15 19:42:31
***************
*** 228,247 ****
--- 228,251 ----
{ "ST380023AS",
WD_QUIRK_SPLIT_MOD15_WRITE },
/*
* This seagate drive seems to have issue addressing sector 0xfffffff
* (aka LBA48_THRESHOLD) in LBA mode. The workaround is to force
* LBA48
*/
{ "ST3200822A",
WD_QUIRK_FORCE_LBA48 },
+ { "ST3200822AS", /* 7200.7 200 GB SATA */
+ WD_QUIRK_FORCE_LBA48 },
+ { "ST3250823AS", /* 7200.8 250 GB SATA */
+ WD_QUIRK_FORCE_LBA48 },
{ NULL,
0 }
};
static const struct wd_quirk *
wd_lookup_quirks(const char *name)
{
const struct wd_quirk *wdq;
const char *estr;