|
|
0dc71c |
From 1c9518bb506f8f4fa6b388571c76797705e7b566 Mon Sep 17 00:00:00 2001
|
|
|
0dc71c |
From: Peter Jones <pjones@redhat.com>
|
|
|
0dc71c |
Date: Tue, 14 Jan 2014 13:12:23 -0500
|
|
|
0dc71c |
Subject: [PATCH 123/143] Make 10_linux work with our changes for linux16 and
|
|
|
0dc71c |
linuxefi on aarch64
|
|
|
0dc71c |
|
|
|
0dc71c |
Signed-off-by: Peter Jones <pjones@redhat.com>
|
|
|
0dc71c |
---
|
|
|
0dc71c |
util/grub.d/10_linux.in | 31 ++++++++++++++++++++++++++++---
|
|
|
0dc71c |
1 file changed, 28 insertions(+), 3 deletions(-)
|
|
|
0dc71c |
|
|
|
0dc71c |
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
|
|
|
0dc71c |
index c943a1e..2b8c561 100644
|
|
|
0dc71c |
--- a/util/grub.d/10_linux.in
|
|
|
0dc71c |
+++ b/util/grub.d/10_linux.in
|
|
|
0dc71c |
@@ -75,8 +75,18 @@ linux_entry ()
|
|
|
0dc71c |
args="$4"
|
|
|
0dc71c |
|
|
|
0dc71c |
sixteenbit=""
|
|
|
0dc71c |
+ linuxefi="linux"
|
|
|
0dc71c |
+ initrdefi="initrd"
|
|
|
0dc71c |
case "$machine" in
|
|
|
0dc71c |
- i?86|x86_64) sixteenbit="16" ;;
|
|
|
0dc71c |
+ i?86|x86_64)
|
|
|
0dc71c |
+ sixteenbit="16"
|
|
|
0dc71c |
+ linuxefi="linuxefi"
|
|
|
0dc71c |
+ initrdefi="initrdefi"
|
|
|
0dc71c |
+ ;;
|
|
|
0dc71c |
+ aarch64)
|
|
|
0dc71c |
+ linuxefi="linux"
|
|
|
0dc71c |
+ initrdefi="initrd"
|
|
|
0dc71c |
+ ;;
|
|
|
0dc71c |
esac
|
|
|
0dc71c |
|
|
|
0dc71c |
if [ -z "$boot_device_id" ]; then
|
|
|
0dc71c |
@@ -133,7 +143,7 @@ linux_entry ()
|
|
|
0dc71c |
fi
|
|
|
0dc71c |
if [ -d /sys/firmware/efi ]; then
|
|
|
0dc71c |
sed "s/^/$submenu_indentation/" << EOF
|
|
|
0dc71c |
- linuxefi ${rel_dirname}/${basename} root=${linux_root_device_thisversion} ro ${args}
|
|
|
0dc71c |
+ ${linuxefi} ${rel_dirname}/${basename} root=${linux_root_device_thisversion} ro ${args}
|
|
|
0dc71c |
EOF
|
|
|
0dc71c |
else
|
|
|
0dc71c |
sed "s/^/$submenu_indentation/" << EOF
|
|
|
0dc71c |
@@ -143,7 +153,7 @@ EOF
|
|
|
0dc71c |
if test -n "${initrd}" ; then
|
|
|
0dc71c |
if [ -d /sys/firmware/efi ]; then
|
|
|
0dc71c |
sed "s/^/$submenu_indentation/" << EOF
|
|
|
0dc71c |
- initrdefi ${rel_dirname}/${initrd}
|
|
|
0dc71c |
+ ${initrdefi} ${rel_dirname}/${initrd}
|
|
|
0dc71c |
EOF
|
|
|
0dc71c |
else
|
|
|
0dc71c |
sed "s/^/$submenu_indentation/" << EOF
|
|
|
0dc71c |
@@ -151,6 +161,13 @@ EOF
|
|
|
0dc71c |
EOF
|
|
|
0dc71c |
fi
|
|
|
0dc71c |
fi
|
|
|
0dc71c |
+ if test -n "${fdt}" ; then
|
|
|
0dc71c |
+ message="$(gettext_printf "Loading fdt ...")"
|
|
|
0dc71c |
+ sed "s/^/$submenu_indentation/" << EOF
|
|
|
0dc71c |
+ echo '$(echo "$message" | grub_quote)'
|
|
|
0dc71c |
+ devicetree ${rel_dirname}/${fdt}
|
|
|
0dc71c |
+EOF
|
|
|
0dc71c |
+ fi
|
|
|
0dc71c |
sed "s/^/$submenu_indentation/" << EOF
|
|
|
0dc71c |
}
|
|
|
0dc71c |
EOF
|
|
|
0dc71c |
@@ -211,6 +228,14 @@ while [ "x$list" != "x" ] ; do
|
|
|
0dc71c |
fi
|
|
|
0dc71c |
done
|
|
|
0dc71c |
|
|
|
0dc71c |
+ fdt=
|
|
|
0dc71c |
+ for i in "dtb-${version}" "dtb-${alt_version}"; do
|
|
|
0dc71c |
+ if test -e "${dirname}/${i}/foundation-v8.dtb" ; then
|
|
|
0dc71c |
+ fdt="${i}/foundation-v8.dtb"
|
|
|
0dc71c |
+ break
|
|
|
0dc71c |
+ fi
|
|
|
0dc71c |
+ done
|
|
|
0dc71c |
+
|
|
|
0dc71c |
config=
|
|
|
0dc71c |
for i in "${dirname}/config-${version}" "${dirname}/config-${alt_version}" "/etc/kernels/kernel-config-${version}" ; do
|
|
|
0dc71c |
if test -e "${i}" ; then
|
|
|
0dc71c |
--
|
|
|
0dc71c |
1.9.3
|
|
|
0dc71c |
|