linuxboot / heads

A minimal Linux that runs as a coreboot or LinuxBoot ROM payload to provide a secure, flexible boot environment for laptops, workstations and servers.
https://osresearch.net/
GNU General Public License v2.0
1.42k stars 185 forks source link

Manjaro and Garuda ISOs won't boot automatically #1605

Open JonathonHall-Purism opened 9 months ago

JonathonHall-Purism commented 9 months ago

Heads can't boot Manjaro or Garuda ISOs. Both of these use variables in the GRUB configuration that Heads doesn't understand.

In this menu item, Heads would need to know the content of "$title" and that it will become "$2" in the menu entry. (This becomes part of the kernel file name and some important command line parameters. $kopt is not critical, it boots without it.)

    title=""
    for kopt in x86_64 $kopts  misobasedir=garuda root=miso:LABEL=GARUDA_DR460NIZED_RAPTOR quiet systemd.show_status=1 ibt=off; do
        if [ -n "$title" ] ; then
            title="$title $kopt";
        else
            title="$kopt";
        fi;
    done
    menuentry "Boot with open source drivers" --class=Garuda.x86_64 "$title" {# set arguments above with the editor
        linux /boot/vmlinuz-$2 driver=free nouveau.modeset=1 i915.modeset=1 radeon.modeset=1
        initrd /boot/amd_ucode.img /boot/intel_ucode.img /boot/initramfs-x86_64.img
    }
JonathonHall-Purism commented 9 months ago

Handling the $2 seems possible if $title wasn't broken in the first place, but handling the loop that sets $title isn't trivial. In this case it would work if executed in a shell, but I'm not sure if that's always true.

This was reported on the Librem 11 and it's possible to boot these manually from the recovery shell as a workaround: https://forums.puri.sm/t/librem-11-seabios-coreboot-does-not-recognize-keyboard-pureboot-does-not-boot-usb/22433/19

tlaurion commented 9 months ago

Non-directly related #1499