tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: blocksizes



tsutsui%ceres.dti.ne.jp@localhost (Izumi Tsutsui) writes:

>The design of FFS is independent from design of our buffercache(9)
>or all disk drivers, so if FFS has its own "disk block size" value
>in its superblock, we have to check and convert (or reject)
>the "FFS disk block size value" for our native I/O size
>whichever we will choose DEV_BSIZE or physical block size.
>(fragment size -> FFS disk block size -> our I/O size)

Ignoring the fsbtodb translation from the superblock is probably
the way to go.


>Note lfs and ext2fs have the same issue.

lfs is obvious (same code as ufs). I haven't looked at ext2fs.


>FYI, Windows XP creates MBR in the first sector even on a removable
>2KB/sec MO disk and it seems to use physical block numbers.

I haven't found an official spec for MBR on non-512byte blocks, but
so far everyone seems to use the first 512 bytes from LBA 0.


>(though our fdisk(8) and mbrlabel(8) don't work on !512bytes/sec disks)

Yes, pretty much hardcoded.

>BPB also uses physical block numbers.

The msdosfs code should handle all block sizes (also on GPT volumes now).

-- 
-- 
                                Michael van Elst
Internet: mlelstv%serpens.de@localhost
                                "A potential Snark may lurk in every tree."


Home | Main Index | Thread Index | Old Index