[Buildroot] devtmpfs and initramfs

Peter Korsgaard jacmet at uclibc.org
Wed Jul 20 10:52:08 UTC 2011


>>>>> "Arnout" == Arnout Vandecappelle <arnout at mind.be> writes:

Hi,

 >> > #!/bin/sh
 >> > # devtmpfs does not get automounted for initramfs'es
 >> > /bin/mount -t devtmpfs devtmpfs /dev
 >> > exec /sbin/init $*
 >> > 
 >> > Unless BR2_ROOTFS_DEVICE_CREATION_STATIC is enabled.
 >> 
 >> Sorry, but this solution smells just like my socks. I think wk can find a
 >> better one :)

 Arnout>  Yeah, I also would prefer not to proliferate the number of
 Arnout> ways that the init process is influenced...

I don't see what there is to dislike. With this, the non-standard
behaviour of initramfs'es is nicely self contained within the initramfs
support code, and nothing else needs to know about it. There's nothing
to tweak, and it just works out of the box (tm), no matter what init
implementation or custom inittab is used.

You could argue that the shell overhead is a bit of a turn down, but
this is no worse than a S01mountall init script.

-- 
Bye, Peter Korsgaard


More information about the buildroot mailing list