From b31ed489b977662292aa39978ee737b94b60af14 Mon Sep 17 00:00:00 2001 From: Aaron Griffin Date: Tue, 6 Jun 2006 05:22:35 +0000 Subject: New error conditions: fail on missing hook or missing module Filesystem hook changes (parseblock handling) Init changes to allow /arch.cmd command line parsing Misc install script cleanups git-svn-id: http://projects.archlinux.org/svn/initramfs/mkinitcpio@123 880c04e9-e011-0410-abf7-b926e227c9cd --- hooks/filesystems | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'hooks') diff --git a/hooks/filesystems b/hooks/filesystems index 12bc945..97d7d57 100644 --- a/hooks/filesystems +++ b/hooks/filesystems @@ -13,15 +13,19 @@ run_hook () /bin/sleep "${rootdelay}" msg "done." export rootdelay=0 - kinit_params="${kinit_params} rootdelay=0" + kparams "rootdelay=0" fi - eval $( /bin/parseblock "${root}") - if [ "${BLOCKNAME}" = "unknown" -o "x{BLOCKDEVICE}" = "x" ]; then + eval $(/bin/parseblock "${root}") + if [ "${BLOCKNAME}" = "unknown" ]; then FSTYPE="unknown" - echo "ERROR: Failed to parse block device '${root}'" + echo "ERROR: Failed to parse block device name for '${root}'" + elif [ "x${BLOCKDEVICE}" = "x" ]; then + FSTYPE="unknown" + echo "ERROR: Failed to parse block device ids for '${root}'" else export root="${BLOCKNAME}" + echo "/bin/mknod \"${BLOCKNAME}\" b ${BLOCKDEVICE}" /bin/mknod "${BLOCKNAME}" b ${BLOCKDEVICE} >/dev/null fi fi @@ -37,7 +41,7 @@ run_hook () if [ "${FSTYPE}" = "unknown" ]; then echo "ERROR: root fs cannot be detected. Try using the rootfstype= kernel parameter." else - kinit_params="${kinit_params} rootfstype=${FSTYPE}" + kparams "rootfstype=${FSTYPE}" /bin/modprobe -q "${FSTYPE}" >/dev/null 2>&1 fi } -- cgit v1.2.3-24-g4f1b