On Sun, Jan 30, 2011 at 08:03:20PM -0800, Matt Thomas wrote:
>
> I do expect the native on NetBSD to know how to get the disklabel location
> for the current machine it's running on from sysctl and not a header file.
That rather depends on where the disk came from.
Since it is relatively easy to move volumes between machines [1]
you actually need to look at the disk to find the label info,
neither a header file nor the kernel know where it will be.
(Clearly the kernel knows what it found if it managed to mount a fs.)
The i386/amd64 code plays 'hunt the disklabel' :-)
David
[1] Otherwise we wouldn't need support for byteswapped fs.
--
David Laight: [email protected]