Subject: Re: new disklabels - part2
To: Greywolf <>
From: Bill Studenmund <>
List: tech-kern
Date: 09/20/1999 16:03:25
On Mon, 20 Sep 1999, Greywolf wrote:

> On Mon, 20 Sep 1999, Bill Studenmund wrote:
> #
> # ...I'd vote for something like /dev/disk, myself...
> Gawd, I know I suggested it, and I know that if we use more than
> 16 partitions per drive, we'll need it, but I really shudder to
> think of /dev/dsk and /dev/rdsk...

I'd vote for just /dev/disk, and put both raw & block disks in there, but
that's me.

> I suppose it wouldn't be too bad were we not to use the c0t0d0s0
> nosense supported by sysv, but I'm still shuddering;  I think I'd
> rather see /dev/{r,}{sd,hd,wd,xy,xd}, than just generic "disk",
> though.

Wel, we have a difference of opinion. :-) I mainly don't want /dev to die
in the process. I'm not so worried about subdividing the disks. Also, I
doubt we'd want to make all 64 device nodes all the time. The first 32 or
so should be more than sufficient (leaving hooks in MAKEDEV to make more).

> # ... [not all the devices would live in the same disklabel] ...
> ...So how do you propose to have partitions 0-63 be consistent
> in meaning across disks?  We gotta standardise on something, here.
> [but see below]

I don't think we can. But if the first eight or 16 have the same meanings
as now, aren't we fine?

> I mean, /dev/rsd/aa needs to have the same rough meaning on one
> disk as it does on the other.  Unless....hmmm...

Right. That's not hard. :-)

> If having many different disklabel types on the disk is essential,
> why not /dev/rsd/0a for the usual filesystem, but /dev/rsd/0msa
> for the first encountered msdos partition, /dev/rsd/3ntc for the
> third encountered NT partition, and the like; i.e., why not explicitly
> name the partition type?
> Of course, this brings us back to the fact that since different
> partitions have different minor numbers, and the humanoid-readable
> device names only correspond to different minor numbers, these
> numbers will need to translate into something meaningful across
> the disks.

We could only do this with something device filesystem. Which mightn't be
a bad thing, but is a seperate question. :-)

> Maybe it's just my mind being unable to wrap itself around abstractions,
> but having labels scattered about randomly between devices -- and trying
> to intuit them in a non-uniform fashion -- seems to me to be borrowing
> trouble.  Don't ask me why.  I'll think on it for a while.

The first 8 or 16 partitions would always correspond to whatever the
current NetBSD partition table corresponds to. The others are more for
compatability with whatever else is out there.

For instance, for MacOS partitioned disks, each partition would correspond
to one on-disk partition. For NetBSD partitioned disks, the first 22 would
correspond to whatever is in the on-disk disklabel. Only with mbr disks
does it get really messy. :-)

Take care,