lkml.org 
[lkml]   [1996]   [Jun]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: possible SCSI device numbering solution
hpa@freya.yggdrasil.com (H. Peter Anvin)  wrote on 27.06.96 in <hpa.31d201d0.Swedes.have.more.fun@freya.yggdrasil.com>:

> Followup to: <199606261829.OAA01794@snowdon.ccs.neu.edu>
> By author: Albert Cahalan <albert@ccs.neu.edu>
> In newsgroup: linux.dev.kernel
> >
> > The major number is useful for character devices, which can be
> > split 12:20. For block devices, a block device is just a block
> > device. If you just need a major number to fill some software
> > "need", then just make it 0 for all block devices.
> >
>
> Huh? The major number is the pointer to the driver; this has to be
> encoded one way or the other, and it might as well be done uniformly
> and efficiently. I'd go for 12:20 if it is deemed enough (which I am
> not really sure about), but dropping the major is a ludicrous idea.

You _could_ combine the "controller number" and the "driver number" into
one field. That just needs a kernel-internal table of controller number ->
driver instead of driver number -> driver. No real problem there.

There's no good reason why device numbering for block devices in a three
controller system should be different between the cases of three equal
controllers, or three different controllers.

* * *

However, I like the idea of having actual partition names. I don't like
the idea of a /vol file system, though.

How about the following:

1. Find a way to assign a permanent name to each partition. There are
several options - Macs already have a name in their partition table, OS/2
has some way (which I keep thinking I should find out about), and lots of
file systems have volume labels. I'm sure _something_ could be worked out.

2. Teach the kernel and mount to (optionally) use partition names. We
might do this similar to nfs, i.e. "mount vol:my_usr_partition /usr". Make
sure this also works with the root= boot option.

This should solve all the problems that we need gigantic minor numbers for
otherwise.

(Oh yes, in case of duplicate names, either complain, or take the first
found, or whatever. That's not really important.)

(Oh yes #2, you can have a /proc/vols or similar so you can easily list
your partition names. Just don't use this for mounting.)

MfG Kai


\
 
 \ /
  Last update: 2005-03-22 13:37    [W:0.053 / U:2.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site