From c6ad92c0f48b40b787137d9ae0926a943a7884b8 Mon Sep 17 00:00:00 2001 From: Heinrich Schuchardt Date: Mon, 17 Oct 2022 13:57:01 +0200 Subject: [PATCH] riscv64: use efi=debug earlycon RISC-V boards tend to boot slowly. We should provide progress information when booting. Use 'efi=debug earlycon' on the Linux command line via new file /etc/default/grub.d/cmdline.cfg. Signed-off-by: Heinrich Schuchardt --- live-build/ubuntu-cpc/hooks.d/base/disk-image-uefi.binary | 5 ++++- live-build/ubuntu-cpc/hooks.d/base/riscv64/grub/cmdline.cfg | 4 ++++ 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 live-build/ubuntu-cpc/hooks.d/base/riscv64/grub/cmdline.cfg diff --git a/live-build/ubuntu-cpc/hooks.d/base/disk-image-uefi.binary b/live-build/ubuntu-cpc/hooks.d/base/disk-image-uefi.binary index 141010d4..3c6bd3dd 100755 --- a/live-build/ubuntu-cpc/hooks.d/base/disk-image-uefi.binary +++ b/live-build/ubuntu-cpc/hooks.d/base/disk-image-uefi.binary @@ -240,6 +240,10 @@ install_grub() { # TODO grub-efi-riscv64 exists, but is not used by all the images yet if [ -n "${SUBARCH:-}" ]; then # Per-device images + local my_d=$(dirname $(readlink -f ${0})) + echo "Adjusting GRUB defaults for ${ARCH}" + mkdir -p mountpoint/etc/default/grub.d/ + cp ${my_d}/riscv64/grub/cmdline.cfg mountpoint/etc/default/grub.d/ case "${SUBARCH}" in "icicle") echo "Installing GRUB for ${SUBARCH} board" @@ -271,7 +275,6 @@ install_grub() { chroot mountpoint rm -f /boot/boot.scr ;; "nezha"|"licheerv") - local my_d=$(dirname $(readlink -f ${0})) echo "Reducing initramfs size for ${SUBARCH} board" mkdir -p mountpoint/etc/initramfs-tools/conf.d/ cp ${my_d}/riscv64/initramfs-tools/modules_list.conf mountpoint/etc/initramfs-tools/conf.d/ diff --git a/live-build/ubuntu-cpc/hooks.d/base/riscv64/grub/cmdline.cfg b/live-build/ubuntu-cpc/hooks.d/base/riscv64/grub/cmdline.cfg new file mode 100644 index 00000000..c8cf57d0 --- /dev/null +++ b/live-build/ubuntu-cpc/hooks.d/base/riscv64/grub/cmdline.cfg @@ -0,0 +1,4 @@ +# Booting on many riscv64 systems is slow. Let the user view progress. +# For minimum output use +# GRUB_CMDLINE_LINUX_DEFAULT="quiet" +GRUB_CMDLINE_LINUX_DEFAULT="efi=debug earlycon"