On Tue, May 24, 2005 at 12:33:39PM +0100, Marty _ wrote:
> never investigated udev to be quite honest, just thought it 
> was another form of devfs from the guide.

It is, in that it dynamically manages the /dev directory.  But it does
this using hotplug events from the kernel, not code inside the kernel.
The default hotplug event seems to give udev a device name, and the
default action for udev is to create a file in the udevdir (which we set
to /dev) with that name, using the proper major, minor, and type
(character vs. block).

Some of these are overridden in the rules files (/dev/input/mouse* and
/dev/input/mice, for example, and Alsa devices into /dev/snd), because
even before devfs, the USB input devices were stuffed under /dev/input.

/dev/mouse itself *seems* to be a de-facto standard.  It looks like
several distros created it so that they could distribute one gpm and X
setup, but have it work with several different mouse types (PS/2, USB,
busmouse, etc.).  The PS/2 driver used to use /dev/psaux.

None of that is necessary anymore with recent kernels -- ALL mouse
drivers are supposed to use the kernel's input subsystem, which uses the
/dev/input/* devices.  So under 2.6, even loading the psaux driver will
create a /dev/input/mouse0 and /dev/input/mice.  Distros could just use
/dev/input/mice instead of /dev/mouse.

That does fall apart if you use a mouse that isn't supported by the
kernel, but requires external drivers instead (some touchscreens
apparently fall into this category).  If those drivers don't use the
kernel input subsystem, you'd need to use their device file.

But whatever.

> To add to your note, there isnt a difference between the two, ive just got 
> so used to slackware's /dev style I couldnt handle the entire directory 
> tree the devfs mount produces.

Then you'll probably be happy to know that udev doesn't do that, at least
not by default.  ;-)

Attachment: pgpsgmsjd5YAE.pgp
Description: PGP signature

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to