Subject: Re: Moving getmaxpartitions to libc
To: None <>
From: Wolfgang Solfrank <>
List: tech-userlevel
Date: 09/01/1999 16:48:27

> There is a difference between tty-parameters and a disklabel. The big one
> being that incase of the tty-parameters, only the hardware keeps state. It
> has no (seeable) software state like an in-core label. So unless the the
> tty-hardware is explicitely modified, the parameters are OK. This is less
> clear with disks (see the dd(1) example).

Hmm, do you think that echo is done by hardware? :-)

> What interests me is how you think it should function. Like when does the
> in-core label come into existence and when and how it gets wiped out...

IMHO, in-core disklabels should normally be read/constructed from information
found on the disk on any first open of one (no particular) partition of the
device after startup or a media change.  And this happens to be the way our
disk drivers (not sure however whether all of them do) do it now.

For your problem with using sunlabel to partition a disk for use in NetBSD
it might make sense to add some ioctl to the disk drivers to invalidate
the incore label.

However I'm not really sure that it's worth to support this; it probably
makes more sense to enhance or rewrite our standard disklabel utility to
provide the same functionality/user friendliness as does the one you

> Oh, on tech-kern a simular discussion popped up subject: 'sd rereads'.

Yes, I was just going to reply to that one, too, but Manuel beat me to it :-).

ws@TooLs.DE     (Wolfgang Solfrank, TooLs GmbH) 	+49-228-985800