I think the correct solution is to put the geometry that you want newfs
to use in the label. The geometry in the label isn't used for many
things other than newfs. It is used for booting and by fdisk. Disk
No, this won't work for IDE drives, which in my experience seem to be very
particular about what geometry is stuffed into the controller. If you put
According to the ATA standard, IDE drives accept any possible geometry
(sectors < 256, heads <= 16, cylinders < 65536).
some geometry in the disklabel that has nothing to do with the geometry
reported by the controller, then when that geometry is stuffed into the
controller when the disk is first opened, it will likely hose things badly.
Problems occur when people put impossible geometries (heads > 16) in the
label and perhaps for nonstandard drives.
slicing will provide separate labels for the whole disk and the BSD
slice (even when the BSD slice is the whole disk) so it will be possible
to have separate geometries for booting/fdisk and newfs.
If this scheme uses the "native" geometry to initialize the controller,
and the BSD geometry for "soft" operations (like newfs) only, then it
Yes. The driver still has to have complications to handle drives that
don't have a (correct) "native" geometry. MFM drives don't report their
geometry, and ESDI drives may report an unusable geometry (with more
cylinders or sectors than can be used). These are currently handled
by a 3-step bootstrap: stuff the controller with a minimal geometry;
use this geometry to read the MBR, guess another geometry and stuff the
controller with it; use the previous geometry to read the label and
stuff the controller with the geometry in the label. It would have
been better to get a usable geometry from the BIOS and never change it.
However, the complicated method works for drives that aren't supported
by the BIOS and/or don't report their geometry correctly (provided the
mbr and/or the label is correctly initialized), and recent BIOSs may
report physically impossible geometries (heads > 16).