diff options
author | Krzysztof Sywula <krzysztof.m.sywula@intel.com> | 2014-01-15 11:27:04 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-01-16 12:03:14 +0000 |
commit | 5a2f4feeaac4f9278fa0cf808c2f495f0c19324f (patch) | |
tree | 0637861f89394e7116658f5ce376de976ecaea6c /meta/recipes-core/initrdscripts/files | |
parent | e38d7702be279d6d6d4c79b3f2379e689a7473d2 (diff) | |
download | openembedded-core-5a2f4feeaac4f9278fa0cf808c2f495f0c19324f.tar.gz openembedded-core-5a2f4feeaac4f9278fa0cf808c2f495f0c19324f.tar.bz2 openembedded-core-5a2f4feeaac4f9278fa0cf808c2f495f0c19324f.zip |
initrdscripts: add $CMDLINE to init-live switch_root
init-live.sh: $CMDLINE variable should be provided to switch_root
to let user specify runlevel on grub command line.
Feeding with -c /dev/console as well as busybox switch_root enables that option.
Signed-off-by: Krzysztof Sywula <krzysztof.m.sywula@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/initrdscripts/files')
-rw-r--r-- | meta/recipes-core/initrdscripts/files/init-live.sh | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/meta/recipes-core/initrdscripts/files/init-live.sh b/meta/recipes-core/initrdscripts/files/init-live.sh index bd259b9902..7e27f91f9e 100644 --- a/meta/recipes-core/initrdscripts/files/init-live.sh +++ b/meta/recipes-core/initrdscripts/files/init-live.sh @@ -89,7 +89,10 @@ boot_live_root() { mount -n --move /dev ${ROOT_MOUNT}/dev cd $ROOT_MOUNT - exec switch_root $ROOT_MOUNT /sbin/init + + # busybox switch_root supports -c option + exec switch_root -c /dev/console $ROOT_MOUNT /sbin/init $CMDLINE || + fatal "Couldn't switch_root, dropping to shell" } fatal() { |