From 851b4e2c2b119692c30f185b1c0d10b07cacc322 Mon Sep 17 00:00:00 2001 From: Aaron Griffin Date: Wed, 14 Jun 2006 01:07:04 +0000 Subject: kinit param handling changes encryption /dev/mapper dir (whoops) git-svn-id: http://projects.archlinux.org/svn/initramfs/mkinitcpio@125 880c04e9-e011-0410-abf7-b926e227c9cd --- hooks/filesystems | 4 ++-- init | 6 +++--- install/encrypt | 1 + 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/hooks/filesystems b/hooks/filesystems index 97d7d57..5ab5c6b 100644 --- a/hooks/filesystems +++ b/hooks/filesystems @@ -13,7 +13,7 @@ run_hook () /bin/sleep "${rootdelay}" msg "done." export rootdelay=0 - kparams "rootdelay=0" + kinit_params="${kinit_params} rootdelay=0" fi eval $(/bin/parseblock "${root}") @@ -41,7 +41,7 @@ run_hook () if [ "${FSTYPE}" = "unknown" ]; then echo "ERROR: root fs cannot be detected. Try using the rootfstype= kernel parameter." else - kparams "rootfstype=${FSTYPE}" + kinit_params="${kinit_params} rootfstype=${FSTYPE}" /bin/modprobe -q "${FSTYPE}" >/dev/null 2>&1 fi } diff --git a/init b/init index 2d8e9c8..2f4c446 100644 --- a/init +++ b/init @@ -2,7 +2,6 @@ msg () { [ "${quiet}" != "y" ] && echo $@; } err () { echo "ERROR: $@"; } -kparams () { echo -n "$@" >> /arch.cmd; } msg ":: Loading Initramfs" @@ -13,12 +12,13 @@ read CMDLINE /proc/sys/kernel/modprobe for cmd in $CMDLINE; do case "$cmd" in - [0123456Ss]) continue ;; + [0123456Ss]) export runlevel="$cmd" ;; *=*) export "${cmd}" ;; *) export "${cmd}=y" ;; esac @@ -81,4 +81,4 @@ fi msg ":: Initramfs Completed - control passing to kinit" echo "/sbin/modprobe" > /proc/sys/kernel/modprobe -exec /bin/kinit "root=${root}" "${CMDLINE}" +exec /bin/kinit -- "root=${root}" ${kinit_params} "${runlevel}" > /dev/null 2>&1 diff --git a/install/encrypt b/install/encrypt index 65007fc..e97734e 100644 --- a/install/encrypt +++ b/install/encrypt @@ -4,6 +4,7 @@ install () { MODULES=" dm-crypt $(all_modules "/crypto/" | grep -v "aes.ko" ) " BINARIES="" + add_dir "/dev/mapper" add_file "/sbin/cryptsetup.static" "/bin/cryptsetup" FILES="" SCRIPT="encrypt" -- cgit v1.2.3-24-g4f1b