Skip to content

Instantly share code, notes, and snippets.

@StefanHamminga
Created March 21, 2019 12:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save StefanHamminga/0bc8e7a547803f550fe406ef01ab94c9 to your computer and use it in GitHub Desktop.
Save StefanHamminga/0bc8e7a547803f550fe406ef01ab94c9 to your computer and use it in GitHub Desktop.
# HiKey970 grub config enabling "grub-reboot 'Experimental kernel'" to one-time boot testing kernels.
if [ -s $prefix/grubenv ]; then
set have_grubenv=true
load_env
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"
set next_entry=
save_env next_entry
set boot_once=true
else
set default="0"
fi
if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi
export menuentry_id_option
if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi
function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
# set default="0"
set timeout=10
menuentry 'Lebian 9 (HiKey970 Lebian)' {
search.fs_label rootfs rootfs_part
linux ($rootfs_part)/boot/Image earlycon=pl011,0xfff32000,115200 clk_ignore_unused=true console=tty0 console=ttyAMA6,115200n8 root=/dev/sdd15 rootwait rw efi=noruntime
devicetree ($rootfs_part)/boot/kirin970-hikey970.dtb
}
menuentry 'Experimental kernel' {
search.fs_label rootfs rootfs_part
# Update these to match your experimental kernel:
linux ($rootfs_part)/boot/Image-experimental earlycon=pl011,0xfff32000,115200 clk_ignore_unused=true console=tty0 console=ttyAMA6,115200n8 root=/dev/sdd15 rootwait rw efi=noruntime
devicetree ($rootfs_part)/boot/hi3670-hikey970-experimental.dtb
}
menuentry 'Fastboot' {
search.fs_label boot boot_part
chainloader ($boot_part)/EFI/BOOT/fastboot.efi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment