Added patch from Tim Steiner <tsteiner@nerdclub.net> to add a real_rootflags parameter for bug #122672.

git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/genkernel/trunk@458 67a159dc-881f-0410-a524-ba9dfbe2cb84
cleanup-cruft
Chris Gianelloni 18 years ago
parent 8edf1cba7d
commit c6db6d2542

@ -2,6 +2,10 @@
# Copyright 2006-2006 Gentoo Foundation; Distributed under the GPL v2 # Copyright 2006-2006 Gentoo Foundation; Distributed under the GPL v2
# $Header: $ # $Header: $
13 Nov 2006; Chris Gianelloni <wolf31o2@gentoo.org> generic/linuxrc:
Added patch from Tim Steiner <tsteiner@nerdclub.net> to add a real_rootflags
parameter for bug #122672.
13 Nov 2006; Chris Gianelloni <wolf31o2@gentoo.org> 13 Nov 2006; Chris Gianelloni <wolf31o2@gentoo.org>
generic/initrd.scripts, generic/linuxrc: generic/initrd.scripts, generic/linuxrc:
Added patch to support resuming from encrypted swap. The patch was submitted Added patch to support resuming from encrypted swap. The patch was submitted

@ -45,6 +45,7 @@ CMDLINE="`cat /proc/cmdline`"
# Scan CMDLINE for any specified real_root= or cdroot arguments # Scan CMDLINE for any specified real_root= or cdroot arguments
REAL_ROOT='' REAL_ROOT=''
FAKE_ROOT='' FAKE_ROOT=''
REAL_ROOTFLAGS=''
for x in ${CMDLINE} for x in ${CMDLINE}
do do
case "${x}" in case "${x}" in
@ -178,6 +179,9 @@ do
crypt_swap\=*) crypt_swap\=*)
LUKS_SWAP=`parse_opt "${x}"` LUKS_SWAP=`parse_opt "${x}"`
;; ;;
real_rootflags\=*)
REAL_ROOTFLAGS=`parse_opt "${x}"`
;;
esac esac
done done
@ -406,7 +410,12 @@ do
# mount ro so fsck doesn't barf later # mount ro so fsck doesn't barf later
# REAL_ROOT_TYPE=`vol_id -t ${REAL_ROOT}` # REAL_ROOT_TYPE=`vol_id -t ${REAL_ROOT}`
# mount -t ${REAL_ROOT_TYPE} -o ro ${REAL_ROOT} ${NEW_ROOT} # mount -t ${REAL_ROOT_TYPE} -o ro ${REAL_ROOT} ${NEW_ROOT}
mount -o ro ${REAL_ROOT} ${NEW_ROOT} if [ "${REAL_ROOTFLAGS}" = '' ]; then
mount -o ro ${REAL_ROOT} ${NEW_ROOT}
else
good_msg "Using mount -o ro,${REAL_ROOTFLAGS}"
mount -o ro,${REAL_ROOTFLAGS} ${REAL_ROOT} ${NEW_ROOT}
fi
fi fi
# If mount is successful break out of the loop # If mount is successful break out of the loop

Loading…
Cancel
Save