ndev

Vladimir Dronnikov dronnikov at gmail.com
Fri Oct 30 12:49:11 UTC 2009


Hello, list!

I've been developing my flavor of BB mdev, but eventually realized it
takes much effort to patch it. As the patch itself grew more than
original utility code, I decided to leave mdev alone and to move
changes to a new applet -- ndev -- source attached.

Reasons to do that:
* I haven't convinced BB to include a part for scanning /sys/devices
(I call it deep coldplug) -- so some other unknown utility/script is
responsible to load missed modules and so on;
* I want to employ netlink -- that way ndev is ready to become runit
service -- thus to be reliably restarted/logged/controlled. Further
improvement can be preparsing of /etc/mdev.conf upon ndev starting;
* netlink messages provide for environment variables to come in
uniform way: just read $DEVPATH/uevent line-by-line, fetch and analyse
needed strings;

I use it as follows:
* in initramfs /init: "ndev -sc" to fast create block device nodes --
they are used to locate root filesystem. -c means don't snoop into
/etc/mdev.conf
* in /sbin/init: "ndev -S &" to perform in background deep search for
all present devices (say, network adapters, too)
* during runtime as daemon to operate hotplug events: "ndev &"

I'd greatly appreciate your reviews, colleagues.

TIA,
--
Vladimir
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ndev.patch
Type: application/octet-stream
Size: 17122 bytes
Desc: not available
URL: <http://lists.busybox.net/pipermail/busybox/attachments/20091030/8bfaf13c/attachment-0001.obj>


More information about the busybox mailing list