Subject: LBA48_THRESHOLD
To: None <tech-kern@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: tech-kern
Date: 01/15/2005 11:41:11
I note in wd.c:


#define LBA48_THRESHOLD         (0xfffffff)     /* 128GB / DEV_BSIZE */
...
        /*
         * 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 },
...
        if (wd->sc_flags & WDF_LBA48 &&
            (wd->sc_wdc_bio.blkno > LBA48_THRESHOLD ||
            (wd->sc_quirks & WD_QUIRK_FORCE_LBA48) != 0))
                wd->sc_wdc_bio.flags |= ATA_LBA48;

I note that the ST3200822A claims only 0x0fffffff sectors when viewed
the LBA way, not 0x10000000, so it's not surprising that it doesn't
like to be addressed the LBA way for a sector that, according to the
LBA interface, is past the end of the drive.

Wouldn't it make more sense for the > to be >=?  ISTM the quirk could
go away then.

/~\ 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