An example mdev.conf

Ned Ludd solar at gentoo.org
Sun Nov 8 22:28:40 UTC 2009


On Sun, 2009-11-08 at 16:00 -0600, Rob Landley wrote:
> On Sunday 08 November 2009 15:02:21 Ned Ludd wrote:
> > Anyway that example conf you are looking at was "before" you did any
> > porting of my first attempt of a mdev.c from that guys mini-udev.c file.
> 
> Apparently in the absence of something better, the LFS guys grabbed your old 
> version. :)

yeah dump that thing if you have not already. It's incompatible.


> > These days my busybox-compat basic confs/script-foo look more like the
> > attached files.
> 
> What's the event stuff for?  I'm not following that...

touchscreen events. Lots of things really expect /dev/event/*
And based on the type of event we are dealing with, I have needed to
setup diff symlinks in a more dynamic way then having to edit every
single mdev.conf for the exact device.

> > fb[0-9] 0:0 0600 @mkdir -pm 755 fb;cd fb && ln -sf ../$MDEV $(echo $MDEV | 
> cut -c 3-)
> > loop[0-9] 0:0 0640 @mkdir -pm 755 loop;cd loop && ln -sf ../$MDEV $(echo 
> $MDEV | cut -c 5-)
> > i2c-[0-9].* 0:0 0660 @mkdir -pm 755 i2c && cd i2c && ln -sf ../$MDEV $(echo 
> $MDEV | cut -c 5-)
> 
> That's looking like a common enough idiom we'd want to support it...

Yeah all the mkdir -m 755 calls annoy me. Would be nice if we could set
a default umask before the systems umask is set. 
Example: when calling mdev from the inittab file.

For testing or even to make a quick set of default devices a feature to
define the /dev/ dir would be good. As well as the ability to use
another mdev.conf vs the system one. Maybe something like

root at device # mdev -s -f ./etc/mdev.conf -d ./dev/

Yes I know patches are welcome :)


> Where's this being used?  Just your personal systems, or is it part of gentoo-
> embeded or the gentoo boot or something?

minimal misc devices I use mdev on. Not related to anything I've pushed
into gentoo.

> (The upshot of this conversation, for me, is I no longer feel I have a clear 
> idea of how this sucker's being used out in the field...)

My usage mainly covers the HTC Wizard phone running Xfbdev (small
community). The AML-M8050 (Nobody really). A beagle board and some other
HTC phone that another dude uses.



More information about the busybox mailing list