Re: Supporting efficient operations on drives with 4K physical s

看板DFBSD_kernel作者時間16年前 (2009/12/29 06:01), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串2/2 (看更多)
This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig414E4974538CAA93A78B7C92 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Matthew Dillon wrote: > It looks like a number of newer drives are going to a 4K physical > sector size (but retaining the 512 byte logical sector size for > the interface). Properly aligned operations wind up being more > efficient. They might support larger (optional?) logical blocks as well, later. Be aware, the standard does not specify that 4KB blocks need to be aligned on 4KB boundaries. HDDs report the alignment and the granularity separately. In light of this, we might want to be able to use an arbitrary offset in the file system or disklabel? > So here's the issue for us. The fdisk program initializes slice 1 > starting at (512 byte) sector #63 instead of 64 in order to align > to the system's idea of a cylinder boundary. This is due to > the 63 sectors/track value: >=20 > cylinders=3D242251 heads=3D256 sectors/track=3D63 (16128 blks/cyl) This value is completely arbitrary, as far as I can tell... > Media sector size is 512 > Warning: BIOS sector numbering starts with sector 1 > Information from DOS bootblock is: > The data for partition 1 is: > sysid 165,(DragonFly/FreeBSD/NetBSD/386BSD) > start 63, size 3907024065 (1907726 Meg), flag 80 (active) > beg: cyl 0/ head 1/ sector 1; > end: cyl 1023/ head 255/ sector 63 > The data for partition 2 is: >=20 > The question is, can we safely modify fdisk to start the > slice in the second sector of the cylinder instead of the > first (cyl 0 head 1 sector 2) in order to align it to > logical sector #64? I think so - every modern system should anyways only use the lba. We should maybe the use 32 sectors per track for CHS (I don't think 64 are allowed) cheers simon --------------enig414E4974538CAA93A78B7C92 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAks5JDMACgkQr5S+dk6z85ofXgCg31gasssR19Mzprn9E1UowKLS B3sAoOO0OqPboqKxUcpSBxsKFQEIGQYo =nvCm -----END PGP SIGNATURE----- --------------enig414E4974538CAA93A78B7C92--
文章代碼(AID): #1BEIgaHU (DFBSD_kernel)
文章代碼(AID): #1BEIgaHU (DFBSD_kernel)