|
|
56d25d |
From d9009de3ff466ed12604d93f92329000aca7b33e Mon Sep 17 00:00:00 2001
|
|
|
56d25d |
From: Peter Jones <pjones@redhat.com>
|
|
|
56d25d |
Date: Thu, 2 Jul 2015 15:06:15 -0400
|
|
|
56d25d |
Subject: [PATCH 41/41] Work around aarch64 not having quite the same grub
|
|
|
56d25d |
commands as x86.
|
|
|
56d25d |
|
|
|
56d25d |
A workaround for a workaround :/
|
|
|
56d25d |
|
|
|
56d25d |
Related: rhbz#1200045
|
|
|
56d25d |
Related: rhbz#1142545
|
|
|
56d25d |
Related: rhbz#1184014
|
|
|
56d25d |
|
|
|
56d25d |
Signed-off-by: Peter Jones <pjones@redhat.com>
|
|
|
56d25d |
---
|
|
|
56d25d |
test.sh | 21 +++++--
|
|
|
56d25d |
test/results/add/g2-1.15.aarch64 | 126 +++++++++++++++++++++++++++++++++++++++
|
|
|
56d25d |
2 files changed, 142 insertions(+), 5 deletions(-)
|
|
|
56d25d |
create mode 100644 test/results/add/g2-1.15.aarch64
|
|
|
56d25d |
|
|
|
56d25d |
diff --git a/test.sh b/test.sh
|
|
|
56d25d |
index 74857af..c2a66e2 100755
|
|
|
56d25d |
--- a/test.sh
|
|
|
56d25d |
+++ b/test.sh
|
|
|
56d25d |
@@ -525,11 +525,22 @@ if [ "$testgrub2" == "y" ]; then
|
|
|
56d25d |
grub2Test grub2.5 add/g2-1.5 --add-kernel=/boot/new-kernel.img \
|
|
|
56d25d |
--title='title' --initrd=/boot/new-initrd --boot-filesystem=/boot/ \
|
|
|
56d25d |
--copy-default
|
|
|
56d25d |
- grub2Test grub2.15 add/g2-1.15 \
|
|
|
56d25d |
- --add-kernel=/boot/vmlinuz-0-rescue-5a94251776a14678911d4ae0949500f5 \
|
|
|
56d25d |
- --initrd /boot/initramfs-0-rescue-5a94251776a14678911d4ae0949500f5.img \
|
|
|
56d25d |
- --copy-default --title "Fedora 21 Rescue" --args=root=/fooooo \
|
|
|
56d25d |
- --remove-kernel=wtf --boot-filesystem=/boot/ --efi
|
|
|
56d25d |
+ case $ARCH in
|
|
|
56d25d |
+ aarch64)
|
|
|
56d25d |
+ grub2Test grub2.15 add/g2-1.15.aarch64 \
|
|
|
56d25d |
+ --add-kernel=/boot/vmlinuz-0-rescue-5a94251776a14678911d4ae0949500f5 \
|
|
|
56d25d |
+ --initrd /boot/initramfs-0-rescue-5a94251776a14678911d4ae0949500f5.img \
|
|
|
56d25d |
+ --copy-default --title "Fedora 21 Rescue" --args=root=/fooooo \
|
|
|
56d25d |
+ --remove-kernel=wtf --boot-filesystem=/boot/ --efi
|
|
|
56d25d |
+ ;;
|
|
|
56d25d |
+ *)
|
|
|
56d25d |
+ grub2Test grub2.15 add/g2-1.15 \
|
|
|
56d25d |
+ --add-kernel=/boot/vmlinuz-0-rescue-5a94251776a14678911d4ae0949500f5 \
|
|
|
56d25d |
+ --initrd /boot/initramfs-0-rescue-5a94251776a14678911d4ae0949500f5.img \
|
|
|
56d25d |
+ --copy-default --title "Fedora 21 Rescue" --args=root=/fooooo \
|
|
|
56d25d |
+ --remove-kernel=wtf --boot-filesystem=/boot/ --efi
|
|
|
56d25d |
+ ;;
|
|
|
56d25d |
+ esac
|
|
|
56d25d |
|
|
|
56d25d |
testing="GRUB2 add initrd"
|
|
|
56d25d |
grub2Test grub2.2 add/g2-1.4 --update-kernel=/boot/new-kernel.img \
|
|
|
56d25d |
diff --git a/test/results/add/g2-1.15.aarch64 b/test/results/add/g2-1.15.aarch64
|
|
|
56d25d |
new file mode 100644
|
|
|
56d25d |
index 0000000..ee5f868
|
|
|
56d25d |
--- /dev/null
|
|
|
56d25d |
+++ b/test/results/add/g2-1.15.aarch64
|
|
|
56d25d |
@@ -0,0 +1,126 @@
|
|
|
56d25d |
+#
|
|
|
56d25d |
+# DO NOT EDIT THIS FILE
|
|
|
56d25d |
+#
|
|
|
56d25d |
+# It is automatically generated by grub2-mkconfig using templates
|
|
|
56d25d |
+# from /etc/grub.d and settings from /etc/default/grub
|
|
|
56d25d |
+#
|
|
|
56d25d |
+
|
|
|
56d25d |
+### BEGIN /etc/grub.d/00_header ###
|
|
|
56d25d |
+set pager=1
|
|
|
56d25d |
+
|
|
|
56d25d |
+if [ -s $prefix/grubenv ]; then
|
|
|
56d25d |
+ load_env
|
|
|
56d25d |
+fi
|
|
|
56d25d |
+if [ "${next_entry}" ] ; then
|
|
|
56d25d |
+ set default="${next_entry}"
|
|
|
56d25d |
+ set next_entry=
|
|
|
56d25d |
+ save_env next_entry
|
|
|
56d25d |
+ set boot_once=true
|
|
|
56d25d |
+else
|
|
|
56d25d |
+ set default="${saved_entry}"
|
|
|
56d25d |
+fi
|
|
|
56d25d |
+
|
|
|
56d25d |
+if [ x"${feature_menuentry_id}" = xy ]; then
|
|
|
56d25d |
+ menuentry_id_option="--id"
|
|
|
56d25d |
+else
|
|
|
56d25d |
+ menuentry_id_option=""
|
|
|
56d25d |
+fi
|
|
|
56d25d |
+
|
|
|
56d25d |
+export menuentry_id_option
|
|
|
56d25d |
+
|
|
|
56d25d |
+if [ "${prev_saved_entry}" ]; then
|
|
|
56d25d |
+ set saved_entry="${prev_saved_entry}"
|
|
|
56d25d |
+ save_env saved_entry
|
|
|
56d25d |
+ set prev_saved_entry=
|
|
|
56d25d |
+ save_env prev_saved_entry
|
|
|
56d25d |
+ set boot_once=true
|
|
|
56d25d |
+fi
|
|
|
56d25d |
+
|
|
|
56d25d |
+function savedefault {
|
|
|
56d25d |
+ if [ -z "${boot_once}" ]; then
|
|
|
56d25d |
+ saved_entry="${chosen}"
|
|
|
56d25d |
+ save_env saved_entry
|
|
|
56d25d |
+ fi
|
|
|
56d25d |
+}
|
|
|
56d25d |
+
|
|
|
56d25d |
+function load_video {
|
|
|
56d25d |
+ if [ x$feature_all_video_module = xy ]; then
|
|
|
56d25d |
+ insmod all_video
|
|
|
56d25d |
+ else
|
|
|
56d25d |
+ insmod efi_gop
|
|
|
56d25d |
+ insmod efi_uga
|
|
|
56d25d |
+ insmod ieee1275_fb
|
|
|
56d25d |
+ insmod vbe
|
|
|
56d25d |
+ insmod vga
|
|
|
56d25d |
+ insmod video_bochs
|
|
|
56d25d |
+ insmod video_cirrus
|
|
|
56d25d |
+ fi
|
|
|
56d25d |
+}
|
|
|
56d25d |
+
|
|
|
56d25d |
+terminal_output console
|
|
|
56d25d |
+if [ x$feature_timeout_style = xy ] ; then
|
|
|
56d25d |
+ set timeout_style=menu
|
|
|
56d25d |
+ set timeout=5
|
|
|
56d25d |
+# Fallback normal timeout code in case the timeout_style feature is
|
|
|
56d25d |
+# unavailable.
|
|
|
56d25d |
+else
|
|
|
56d25d |
+ set timeout=5
|
|
|
56d25d |
+fi
|
|
|
56d25d |
+### END /etc/grub.d/00_header ###
|
|
|
56d25d |
+
|
|
|
56d25d |
+### BEGIN /etc/grub.d/10_linux ###
|
|
|
56d25d |
+menuentry 'Fedora 21 Rescue' --class fedora --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-3.15.0-0.rc5.git2.10.fc21.x86_64-advanced-a14e3dcb-ade3-42f7-832f-d9f66b5ae6a3' {
|
|
|
56d25d |
+ load_video
|
|
|
56d25d |
+ set gfxpayload=keep
|
|
|
56d25d |
+ insmod gzio
|
|
|
56d25d |
+ insmod part_msdos
|
|
|
56d25d |
+ insmod ext2
|
|
|
56d25d |
+ set root='hd0,msdos1'
|
|
|
56d25d |
+ if [ x$feature_platform_search_hint = xy ]; then
|
|
|
56d25d |
+ search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 --hint='hd0,msdos1' 6169b46f-0257-4319-b2e4-caaed2a8e06b
|
|
|
56d25d |
+ else
|
|
|
56d25d |
+ search --no-floppy --fs-uuid --set=root 6169b46f-0257-4319-b2e4-caaed2a8e06b
|
|
|
56d25d |
+ fi
|
|
|
56d25d |
+ linuxefi /vmlinuz-0-rescue-5a94251776a14678911d4ae0949500f5 root=/fooooo ro rd.lvm.lv=fedora_uefi/root rd.lvm.lv=fedora_uefi/swap rhgb quiet
|
|
|
56d25d |
+ initrd /initramfs-0-rescue-5a94251776a14678911d4ae0949500f5.img
|
|
|
56d25d |
+}
|
|
|
56d25d |
+menuentry 'Fedora, with Linux 3.15.0-0.rc5.git2.10.fc21.x86_64' --class fedora --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-3.15.0-0.rc5.git2.10.fc21.x86_64-advanced-a14e3dcb-ade3-42f7-832f-d9f66b5ae6a3' {
|
|
|
56d25d |
+ load_video
|
|
|
56d25d |
+ set gfxpayload=keep
|
|
|
56d25d |
+ insmod gzio
|
|
|
56d25d |
+ insmod part_msdos
|
|
|
56d25d |
+ insmod ext2
|
|
|
56d25d |
+ set root='hd0,msdos1'
|
|
|
56d25d |
+ if [ x$feature_platform_search_hint = xy ]; then
|
|
|
56d25d |
+ search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 --hint='hd0,msdos1' 6169b46f-0257-4319-b2e4-caaed2a8e06b
|
|
|
56d25d |
+ else
|
|
|
56d25d |
+ search --no-floppy --fs-uuid --set=root 6169b46f-0257-4319-b2e4-caaed2a8e06b
|
|
|
56d25d |
+ fi
|
|
|
56d25d |
+ linuxefi /vmlinuz-3.15.0-0.rc5.git2.10.fc21.x86_64 root=/dev/mapper/fedora_uefi-root ro rd.lvm.lv=fedora_uefi/root rd.lvm.lv=fedora_uefi/swap rhgb quiet
|
|
|
56d25d |
+}
|
|
|
56d25d |
+
|
|
|
56d25d |
+### END /etc/grub.d/10_linux ###
|
|
|
56d25d |
+
|
|
|
56d25d |
+### BEGIN /etc/grub.d/20_linux_xen ###
|
|
|
56d25d |
+
|
|
|
56d25d |
+### END /etc/grub.d/20_linux_xen ###
|
|
|
56d25d |
+
|
|
|
56d25d |
+### BEGIN /etc/grub.d/20_ppc_terminfo ###
|
|
|
56d25d |
+### END /etc/grub.d/20_ppc_terminfo ###
|
|
|
56d25d |
+
|
|
|
56d25d |
+### BEGIN /etc/grub.d/30_os-prober ###
|
|
|
56d25d |
+### END /etc/grub.d/30_os-prober ###
|
|
|
56d25d |
+
|
|
|
56d25d |
+### BEGIN /etc/grub.d/40_custom ###
|
|
|
56d25d |
+# This file provides an easy way to add custom menu entries. Simply type the
|
|
|
56d25d |
+# menu entries you want to add after this comment. Be careful not to change
|
|
|
56d25d |
+# the 'exec tail' line above.
|
|
|
56d25d |
+### END /etc/grub.d/40_custom ###
|
|
|
56d25d |
+
|
|
|
56d25d |
+### BEGIN /etc/grub.d/41_custom ###
|
|
|
56d25d |
+if [ -f ${config_directory}/custom.cfg ]; then
|
|
|
56d25d |
+ source ${config_directory}/custom.cfg
|
|
|
56d25d |
+elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
|
|
|
56d25d |
+ source $prefix/custom.cfg;
|
|
|
56d25d |
+fi
|
|
|
56d25d |
+### END /etc/grub.d/41_custom ###
|
|
|
56d25d |
--
|
|
|
56d25d |
2.4.3
|
|
|
56d25d |
|