summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xinit16
-rwxr-xr-xmkinitramfs3
2 files changed, 7 insertions, 12 deletions
diff --git a/init b/init
index b221bb1..8330797 100755
--- a/init
+++ b/init
@@ -69,29 +69,25 @@ parse_cmdline() {
root=*)
if [ "${i:5:4}" == 'UUID' ]; then
# mount by uuid
- local uuid=$(echo ${i} | cut -d '=' -f 3)
- ROOTDEV="$(blkid -U ${uuid})"
+ ROOTDEV="/dev/disk/by-uuid/${i##*=}"
elif [ "${i:5:5}" == 'LABEL' ]; then
# mount by label
- local label=$(echo ${i} | cut -d '=' -f 3)
- ROOTDEV="$(blkid -L ${label})"
+ ROOTDEV=/dev/disk/by-partlabel/${i##*=}
else
# mount by dev
- ROOTDEV="$(echo ${i} | cut -d '=' -f 2)"
+ ROOTDEV="${i##*=}"
fi
;;
cryptroot=*)
if [ "${i:10:4}" == 'UUID' ]; then
# mount by uuid
- local uuid=$(echo ${i} | cut -d '=' -f 3)
- CRYPTROOT="$(blkid -U ${uuid})"
+ CRYPTROOT="/dev/disk/by-uuid/${i##*=}"
elif [ "${i:10:5}" == 'LABEL' ]; then
# mount by label
- local label=$(echo ${i} | cut -d '=' -f 3)
- CRYPTROOT="$(blkid -L ${label})"
+ CRYPTROOT=/dev/disk/by-partlabel/${i##*=}
else
# mount by dev
- CRYPTROOT="$(echo ${i} | cut -d '=' -f 2)"
+ CRYPTROOT="${i##*=}"
fi
;;
subvol=*)
diff --git a/mkinitramfs b/mkinitramfs
index 5d35386..676c770 100755
--- a/mkinitramfs
+++ b/mkinitramfs
@@ -19,7 +19,6 @@
# Hash of fully-qualified binaries
declare -a fqbins
-
#
# Searches PATH for all binaries listed as function arguments. Each found
# binary is then put into the global "bins" array.
@@ -204,7 +203,7 @@ function main {
# List of binaries to exist in the new initramfs
# Standard shell binaries
- resolve_bins bash cat pidof ps ls clear cut grep less blkid switch_root kill
+ resolve_bins bash cat pidof ps ls clear grep less switch_root kill
# Module management
resolve_bins udevadm udevd modprobe rmmod
# For encrypted and block device support

Generated by cgit