Pass disk context to GRUB

Garrett Brown garrett.brown at aclimalabs.com
Tue Jun 23 17:52:25 CEST 2020


Hello,

I'm trying to enable UEFI dual-booting on the BeagleBone black. U-Boot
knows to boot from SD if present, and eMMC if not. However, U-Boot doesn't
pass the disk "context" to GRUB; GRUB always thinks it's booting from
`hd0`, and doesn't know what to use for the kernel's `root` parameter.

I checked the UEFI API, and it seems U-Boot passes a handle to the disk
that the GRUB EFI loader was loaded from. Is it possible to also pass a
value that can be used to determine the kernel's `root` based on if we're
booting from SD or eMMC (and in the future, USB)?

For more context, see
https://github.com/mendersoftware/meta-mender/pull/1010#issuecomment-647172447
.

Thank you,
Garrett


More information about the U-Boot mailing list