Messages in this thread | | | From | (david parsons) | Subject | Re: PUBLIC CHALLENGE: (was RE: devfs again, (was RE: USB device a lloc ation) ) | Date | 9 Oct 1999 23:58:07 -0700 |
| |
In article <linux.kernel.19991010011136.C30460@wookie.chirp.com.au>, Nathan Hand <nathanh@chirp.com.au> wrote: >On Fri, Oct 08, 1999 at 02:38:37PM -0700, david parsons wrote: >> >> It solves the problems I have with the existing black magic >> system, which is that I want the kernel to tell me what devices >> it has on it. > >Would a /proc/devices file which lists all devices also solve your >problems with the existing system?
No, not really. I was working on something like that myself before richard gooch published his devfs -- I was building a /proc/dev for 2.0.x, with the idea that the machine would come up, and a daemon would massage dev with the appropriate major and minor numbers. When richard announced his devfs, I complained bitterly about one or another thing in it, up until I realized that, no, I was wrong and that they way he did it was far more useful, because I could use it the way I originally intended, plus I could automatically mount it and build much more efficient installers and appliance systems.
>I like the /proc/devices idea. It's relatively simple.
But it's not as versatile as a real devfs is, and I don't see that stripping functionality out of a devfs (without any benefit over the real thing; you still have to write the filesystem glue, plus you still need to tweak all the appropriate-level drivers to populate the filesystem) _just to prevent people from mounting it on /dev_ is anything other than a political instead of a technical decision.
Yeah, Al Viro has complained that it does unspecified horrible things to the VFS. But I'm not convinced.
>But a /proc/devices will still let you have your autodetection and >let me have a dynamically changing /dev.
Unfortunately, /proc does not allow userland to create entries, otherwise you'd be able to mount a devfs on /proc/devices right now (at least in 2.0.28, I can mount devices on /proc/net, /proc/scsi, and so on. It looks really gross, but it works, if you can ignore the piteous whining from the net tools as they become horribly confused at the FreeBSD ISO image that's in /dev/net) If devfs was in the kernel, this would be a good time to write a generalized virtual fs, and then the kernel could instantiate[1] two copies of it, one for /proc (mounted as immutable, or mutable, take your choice) and one for /proc/devices, /devices, or /dev for those people who want to use it for that.
____ david parsons \bi/ /proc/partitions is a pretty good reason to put \/ devfs into the kernel now.
- 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/
| |