|
|
f731ee |
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
f731ee |
From: Peter Jones <pjones@redhat.com>
|
|
|
f731ee |
Date: Mon, 16 Jul 2012 18:57:11 -0400
|
|
|
f731ee |
Subject: [PATCH] Use "linuxefi" and "initrdefi" where appropriate.
|
|
|
f731ee |
|
|
|
f731ee |
---
|
|
|
f731ee |
util/grub.d/10_linux.in | 18 ++++++++++++++++--
|
|
|
f731ee |
1 file changed, 16 insertions(+), 2 deletions(-)
|
|
|
f731ee |
|
|
|
f731ee |
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
|
|
|
f731ee |
index 00d193159e9..ad34cc02d36 100644
|
|
|
f731ee |
--- a/util/grub.d/10_linux.in
|
|
|
f731ee |
+++ b/util/grub.d/10_linux.in
|
|
|
f731ee |
@@ -127,17 +127,31 @@ linux_entry ()
|
|
|
f731ee |
printf '%s\n' "${prepare_boot_cache}" | sed "s/^/$submenu_indentation/"
|
|
|
f731ee |
fi
|
|
|
f731ee |
message="$(gettext_printf "Loading Linux %s ..." ${version})"
|
|
|
f731ee |
- sed "s/^/$submenu_indentation/" << EOF
|
|
|
f731ee |
+ if [ -d /sys/firmware/efi ]; then
|
|
|
f731ee |
+ sed "s/^/$submenu_indentation/" << EOF
|
|
|
f731ee |
+ echo '$(echo "$message" | grub_quote)'
|
|
|
f731ee |
+ linuxefi ${rel_dirname}/${basename} root=${linux_root_device_thisversion} ro ${args}
|
|
|
f731ee |
+EOF
|
|
|
f731ee |
+ else
|
|
|
f731ee |
+ sed "s/^/$submenu_indentation/" << EOF
|
|
|
f731ee |
echo '$(echo "$message" | grub_quote)'
|
|
|
f731ee |
linux ${rel_dirname}/${basename} root=${linux_root_device_thisversion} ro ${args}
|
|
|
f731ee |
EOF
|
|
|
f731ee |
+ fi
|
|
|
f731ee |
if test -n "${initrd}" ; then
|
|
|
f731ee |
# TRANSLATORS: ramdisk isn't identifier. Should be translated.
|
|
|
f731ee |
message="$(gettext_printf "Loading initial ramdisk ...")"
|
|
|
f731ee |
- sed "s/^/$submenu_indentation/" << EOF
|
|
|
f731ee |
+ if [ -d /sys/firmware/efi ]; then
|
|
|
f731ee |
+ sed "s/^/$submenu_indentation/" << EOF
|
|
|
f731ee |
echo '$(echo "$message" | grub_quote)'
|
|
|
f731ee |
+ initrdefi ${rel_dirname}/${initrd}
|
|
|
f731ee |
+EOF
|
|
|
f731ee |
+ else
|
|
|
f731ee |
+ sed "s/^/$submenu_indentation/" << EOF
|
|
|
f731ee |
+ echo '$message'
|
|
|
f731ee |
initrd ${rel_dirname}/${initrd}
|
|
|
f731ee |
EOF
|
|
|
f731ee |
+ fi
|
|
|
f731ee |
fi
|
|
|
f731ee |
sed "s/^/$submenu_indentation/" << EOF
|
|
|
f731ee |
}
|