lkml.org 
[lkml]   [1999]   [Jun]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Devfs, was Re: Migrating to larger numbers
Wakko Warner writes:
> > > > > /dev/parport/cd
> > > > > /dev/pcmcia/cd
> > > > > /dev/usb/cd
> > > > >
> > > > > Doesn't look like the right way to me.
> > >
> > > <serious replies only, I don't want flames for asking a question>
> > > Why bother seperating it out by interface? I'm just asking. It
> > > seems it would be better to go by controller/bus/id/lun[/partition]
> > > for all devices that connect to scsi, ide, usb, pcmcia, parport,
> > > etc. It could get ugly having all of them in the same machine, or
> > > we could do it with the device name beginning with h for ide (like
> > > it is now actually), p for parport, (pcmcia is just another bus like
> > > isa/pci to me so I feel it's irrelevent), s for scsi, u for usb.
> > > say: u0b0i0l0 is id 0 on first bus on first usb controller..
> > > Obviously, I don't know if usb has more than 1 bus per controller, I
> > > know scsi does (used to have a dual channel adaptec eisa at one
> > > time)
> >
> > There are good reasons for separating out the interface types. The
> > first is that it allows an interface driver (ide-cd, sr_mod and so on)
> > to manage a subdirectory. This makes the CD-ROM searching scheme I
> > outlined trivial to implement.
>
> I thought about that a little more... I was thinking that devfs or the
> driver could have a link to the above or something...

No, that defeats the searching scheme. What you want is:
- no driver: no directory
- driver loaded: directory with one entry per piece of hardware
- opendir ("/dev/ide/cd"): load driver.

Putting in symlinks like in your scheme requires a symlink for every
possible entry that might ever exist if you installed an array of
CD-ROMs. That gets us back to pre-devfs days.

> I really like the idea of solaris having this for scsi0 id0 lun0 partition0:
> /dev/dsk/c0t0d0s0 I just don't like the letters they used.
>
> Above where I said bus[0-9], forget it, it would be too hard to do that and
> it would be easier to have c0 and c1 being controller 0 bus 0 and controller
> 0 bus 1. Whoever thought of /dev/sdb being 2nd found scsi hard drive should
> be shot (IMO) I thought about running that user space thing, but I don't
> like the idea of it since the rootfs is mounted via /dev/sdx by the kernel.
> This is the exact reason I put my hard drives as close to id0 as possible
> and all my other drives as close to id6 as possible. if my cd changer goes
> out, my burner goes from scd5 to scd0.. ouch! I only have 1 tape drive in
> this machine so that I'm not TOO worried about. But I thought about this,
> if I ever get a wide card, there's no way I'm putting a wide hdd on an id
> less than 8. This leaves enough room for all my narrow drives
>
> Anyway, I don't feel it would be right to yank the /dev/sda out of the way
> for people who like it, but it would be a nice config option... Atleast
> that would suit the people who love /dev/s{cd,da,t} and for those who can't
> stand it.. Me I can live with it, but I don't like it... Where's my choise
> =)

Have you actually looked at the patch or at least the documentation?
The location-based naming scheme you want is implemented in devfs. And
the old names are still there. And there are boot option to give you
choice.

It's all done. A year ago.

Regards,

Richard....
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:52    [from the cache]
©2003-2011 Jasper Spaans