Subject: Re: Disks with 128 or 256 bytes per sector
To: None <tech-kern@netbsd.org>
From: Wolfgang Solfrank <ws@tools.de>
List: tech-kern
Date: 06/05/2001 17:39:16
Hi,
> I'm not familiar with the work in question. But are you sure that's
> support for 2k physical sectors? To really support 2k physical sectors,
> the disk driver for them would have to have been written/changed to do all
> its i/o in terms of DEV_BSIZE lumps. Among other things, thats all the
> buffer cache understands.
>
> For sizes smaller than DEV_BSIZE, it's not that hard - you just scale
> everything. Like the hpib disk driver - it grabs 2 256-byte sectors when
> one 512-byte sector is requested. For sizes larger than DEV_BSIZE, either
> you'd have to make sure the requests mapped into an integer number of
> blocks (for 2k sectors and 512 byte DEV_BSIZE that's all requests are for
> multiples of 4 blocks and on offsets divisable by 4), or you might have to
> read more than you need (read one 2k sector to get a given 512-bytes out
> of it).
Hmm, I haven't looked yet, how it does it, but you are aware that we
have to do something like this for access to CDs, aren't you?
After all, CDs do have a physical sector size of 2k. And of course they
are supported along standard 512-byte sectored hard disks.
(As an aside, there are CD drives which support switching the physical
block size (of course only by emulation, as they cannot change the
physical blocks on the CD :-)), but those are not the only ones which
we support.)
Ciao,
Wolfgang
--
ws@TooLs.DE Wolfgang Solfrank, TooLs GmbH +49-228-985800