summaryrefslogtreecommitdiff
path: root/resources/scripts/build/boot
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2021-11-30 18:44:08 +0000
committerLeah Rowe <leah@libreboot.org>2021-11-30 18:44:08 +0000
commit4b64e34fc2d3ebfe22d350f0b04023fe60e0df3e (patch)
tree094bf47d791057e195d730a2ea6cbf06da2eeb70 /resources/scripts/build/boot
parentc7944c0e019f686bf189a872391d1f35a3775364 (diff)
build/roms: warn if grub_scan_disk is not set at all
Diffstat (limited to 'resources/scripts/build/boot')
-rwxr-xr-xresources/scripts/build/boot/roms_helper7
1 files changed, 6 insertions, 1 deletions
diff --git a/resources/scripts/build/boot/roms_helper b/resources/scripts/build/boot/roms_helper
index f4eeccf9..d98195f1 100755
--- a/resources/scripts/build/boot/roms_helper
+++ b/resources/scripts/build/boot/roms_helper
@@ -49,7 +49,7 @@ fi
# Workaround to grub's slow boot
-grub_scan_disk="both" # both: scan ata and ahci (slow), there is ata and ahci too
+grub_scan_disk="undefined" # both: scan ata and ahci (slow), there is ata and ahci too
# as an option
cbtree="undefined"
romtype="normal" # optional parameter in board.cfg. "normal" is default
@@ -65,6 +65,11 @@ payload_memtest="n"
# Override the above defaults using board.cfg
source "resources/coreboot/${board}/board.cfg"
+if [ "${grub_scan_disk}" = "undefined" ]; then
+ printf "build/roms: Target %s does not define grub_scan_disk. Defaulting to 'both'.\n" "${board}"
+ grub_scan_disk="both"
+fi
+
if [ "${grub_scan_disk}" != "both" ] && \
[ "${grub_scan_disk}" != "ata" ] && \
[ "${grub_scan_disk}" != "ahci" ]; then