Re: DevFS vs. normal /dev (was DEVFSv50 and /dev/fb? (or /dev/fb/? ???))

Michael H. Warfield (mhw@alcove.wittsend.com)
Tue, 11 Aug 1998 12:05:08 -0400 (EDT)


Horst von Brand enscribed thusly:
> Shawn Leas <sleas@ixion.honeywell.com> said:
> > On Mon, 10 Aug 1998, Horst von Brand wrote:
> > > How do you reference, say, /dev/fd0 if the floppy module isn't even loaded?
> > > You need to do that so kmod loads the module, as things stand now.

> > Under /devfs, the /dev/fd0 is a link to /dev/floppy/0, so the devfs would
> > see the explicit request for /dev/floppy device, and send "floppy" to
> > kmod, and you can alias whatever module that would need to be loaded to
> > floppy.

> So you don't have lots of device files, but "links" for each possible
> device instead (Note that I asked how you access a device that is _not_
> configured into the kernel; the module might even have been build and
> installed from third-party sources just before the reference)? Doesn't
> make much sense to me...

> > It would be loaded automagically. My explaination might be warped, but
> > the basic idea stands.

> That basic idea sounds just like a hand-managed /dev directory, just very
> much harder to do since you have to screw around with the kernel each time
> you want to add something. Or a terrible mess in /proc/add-your-devices-here
> I don't see how it might buy anything in return for the bloat and mess.

Gee... This is begining to sound more and more like the way
Solaris does dynamic devices with their "/devices" directory being
built from driver information and tons and tons of symlinks from the
/dev directory to the real devices in the /devices directory. Works
great, as long as everything works right. :-( When something gets
screwy you can boot the system back up with a "-r" option to rebuild
the devices area. Don't know how much all those symlinks add to the
reputation of "Slowlaris" though. If that's the road we are starting
to walk down, I stick with the old style /dev directory and mknod,
thank you.

They're actually not using an idea like devfs but are using
configuration files for all of their drivers. They then use the
drivers and the configuration files during a rebuild to autobuild
the /devices directory. That can be triggered by either new hardware
or the -r option to the boot command. Having done device drivers
for SunOS 4.x and Solaris (SunOS 5.x), sometimes I think they ended
up with the worst of both possible worlds when they did that.

That's also why I'm somewhat sceptical about devfs. While it
may well be very useful for some things, I can see trouble in practice
and I doubt it will ever totally replace the normal /dev directory.
But it's also very hard to predict where the problems will be until
it gets more use, so I'm interested in seeing it in the kernel as an
option (but hey - I was for seeing Solar Designers security patches
in the kernel and that got nowhere after a very similar religious
debate). I could be wrong, but I suspect devil's in those details...

> --
> Horst von Brand vonbrand@sleipnir.valparaiso.cl
> Casilla 9G, Viņa del Mar, Chile +56 32 672616

Mike

-- 
 Michael H. Warfield    |  (770) 985-6132   |  mhw@WittsEnd.com
  (The Mad Wizard)      |  (770) 925-8248   |  http://www.wittsend.com/mhw/
  NIC whois:  MHW9      |  An optimist believes we live in the best of all
 PGP Key: 0xDF1DD471    |  possible worlds.  A pessimist is sure of it!

- 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.altern.org/andrebalsa/doc/lkml-faq.html