grub.cfg: handle extlinux in the default menuentry
isolinux/syslinux/extlinux config files should all work, using the syslinux parser function in grub the current behaviour is to only search for grub.cfg, so extlinux users can't use the default libreboot setup. with this change, their systems should hopefully work. Signed-off-by: Leah Rowe <leah@libreboot.org>9020vga
parent
eaa1341b9e
commit
c4544e04bb
|
@ -92,13 +92,21 @@ function search_isolinux {
|
|||
done
|
||||
echo # Insert newline
|
||||
}
|
||||
function try_bootcfg {
|
||||
try_user_config "${1}"
|
||||
try_isolinux_config "${1}"
|
||||
}
|
||||
function search_bootcfg {
|
||||
search_grub "${1}"
|
||||
search_isolinux "${1}"
|
||||
}
|
||||
menuentry 'Load Operating System (incl. fully encrypted disks) [o]' --hotkey='o' {
|
||||
|
||||
if [ "${grub_scan_disk}" != "ata" ]; then
|
||||
search_grub ahci
|
||||
search_bootcfg ahci
|
||||
fi
|
||||
if [ "${grub_scan_disk}" != "ahci" ]; then
|
||||
search_grub ata
|
||||
search_bootcfg ata
|
||||
fi
|
||||
|
||||
# grub device enumeration is very slow, so checks are hardcoded
|
||||
|
@ -113,7 +121,7 @@ menuentry 'Load Operating System (incl. fully encrypted disks) [o]' --hotkey='o
|
|||
# TODO: optimize grub itself, and use */? here for everything
|
||||
|
||||
for vol in ${lvmvol} ${raidvol} ; do
|
||||
try_user_config "${vol}"
|
||||
try_bootcfg "${vol}"
|
||||
done
|
||||
|
||||
unset ahcidev
|
||||
|
@ -139,13 +147,13 @@ menuentry 'Load Operating System (incl. fully encrypted disks) [o]' --hotkey='o
|
|||
|
||||
# after cryptomount, lvm volumes might be available
|
||||
for vol in ${lvmvol}; do
|
||||
try_user_config "${vol}"
|
||||
try_bootcfg "${vol}"
|
||||
done
|
||||
|
||||
search_grub crypto
|
||||
search_bootcfg crypto
|
||||
|
||||
for vol in lvm/* ; do
|
||||
try_user_config "${vol}"
|
||||
try_bootcfg "${vol}"
|
||||
done
|
||||
|
||||
true # Prevent pager requiring to accept each line instead of whole screen
|
||||
|
|
Loading…
Reference in New Issue