lkml.org 
[lkml]   [1998]   [Jan]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: PROPOSAL: /proc/dev
Ok, suppose that some app does depend on readdir() or stat() indicating
that the file /dev/foo exists.

Under the current fs-based scheme, some program, at some time, called
mknod() to create /dev/foo. After that, optionally, some more programs
could have called chown() and chmod().

Here is what happens under Richard Gooch's scheme: the program that
calls mknod() can continue to call mknod(), and chown() and chmod()
if it wants. Entries created by mknod() will persist across reboots.

Thus if you want to have /dev/foo always present, even when the driver
is not resident and not currently loaded, just mknod(1) it.

One feature of devfs is that it gets rid of major and minor numbers.
In some other way, /dev/foo gets associated with the foo driver.

Hmmm, perhaps this advantage could be separated out and made to work
with the existing system. A new major number of "auto-resolve" would
cause the kernel to resolve the filename to a device driver. I don't
know if this is a feasible idea or not.

Michael Chastain
<mailto:mec@shout.net>
"love without fear"

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