aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIgor Stoppa <igor.stoppa@intel.com>2016-07-01 15:53:52 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-07-08 09:57:26 +0100
commitd6a43d222d547054916a8c55e4ae9ca91a3f0687 (patch)
treedacb5bf72587cdf7fc9dcda7a81dad46c3ef15fa
parentee6a6c3461694ce09789bf4d852cea2e22fc95e4 (diff)
downloadopenembedded-core-contrib-d6a43d222d547054916a8c55e4ae9ca91a3f0687.tar.gz
initramfs-framework: Add support for PartUUIDs
The rootfs can be addressed also by referring to the PartUUID value from the GPT. This patch enables such type of reference. (From OE-Core rev: 1ab2ca141d3defe4b80212e28ac7c3f2271e2515) Signed-off-by: Igor Stoppa <igor.stoppa@intel.com> Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-core/initrdscripts/initramfs-framework/rootfs5
1 files changed, 5 insertions, 0 deletions
diff --git a/meta/recipes-core/initrdscripts/initramfs-framework/rootfs b/meta/recipes-core/initrdscripts/initramfs-framework/rootfs
index 5790d8cb8b..14768f1cd4 100644
--- a/meta/recipes-core/initrdscripts/initramfs-framework/rootfs
+++ b/meta/recipes-core/initrdscripts/initramfs-framework/rootfs
@@ -26,6 +26,11 @@ rootfs_run() {
bootparam_root="/dev/disk/by-uuid/$root_uuid"
fi
+ if [ "`echo ${bootparam_root} | cut -c1-9`" = "PARTUUID=" ]; then
+ root_uuid=`echo $bootparam_root | cut -c10-`
+ bootparam_root="/dev/disk/by-partuuid/$root_uuid"
+ fi
+
if [ -e "$bootparam_root" ]; then
flags=""
if [ -n "$bootparam_ro" ] && ! echo "$bootparam_rootflags" | grep -w -q "ro"; then