[BusyBox] devfsd

Manuel Novoa III mjn3 at codepoet.org
Sat Aug 23 17:47:05 UTC 2003


Hello,

On Fri, Aug 22, 2003 at 05:45:07PM +0200, Matteo Croce wrote:
> Here there is the patch file that add devfsd to busybox.
> It compile whith no errors on my computer. My configuration:
> (RedHat 9.0, custom 2.4.21-xfs-acpi kernel, gcc 3.2.2).
> It is not yet fully optimized, but it works.

It will not build with uClibc because uClibc does not support the
yp_* functions.  If you check the mailing list archive, you should
find a patch for an older version of devfsd that addresses this.

There are several globally visibile functions/variables that need
to be made static to avoid namespace pollution.

As you said... it needs to be optimized.  Most of the items in the
data section can be moved to the text section by appropriate use of
const.  Also, any statics at file scope initialized to 0, FALSE, or
NULL can have their initializers removed since BSS initialization
will take care of them.  After that, there is a fair amount of
redundancy in the code that could be removed.  I wouldn't be surprised
if you could easily trim several k from the object size.

In short, it needs more work.

> I made a bootdisk with devfs support, and the space used by the devfsd
> applet (30k) is less than the space wasted by the entries in a old /dev
> directory.

Space savings depends on what you are doing.  Often you don't need a
fully populated /dev directory.  And don't forget about the increase
in kernel size to support devfs.

Manuel



More information about the busybox mailing list