[U-Boot] [PATCH] EFI: find EFI system partition by legacy MBR partition type
Thomas Schmitt
scdbackup at gmx.net
Thu Jul 6 10:19:29 UTC 2017
Hi,
i am the upstream developer of program xorriso which packs up Debian arm64
ISOs.
Here is my minority opinion from a discussion with Andre Przywara:
To my opinion, if U-boot is used as EFI implementation, then it should
not consider as bootable any "active" MBR partitions or "Legacy BIOS
Bootable" GPT partitions (see is_bootable() in disk/part_efi.c).
While the proposed change of behavior is an undisputable improvement,
my objection is that the main boot loaders in distro ISOs are GRUB and
SYSLINUX. Both do not expect that the "active" partition gets booted by
the firmware but rather that their own MBR at the start of the ISO gets
started by BIOS or the ESP is brought up by EFI.
The MBR programs in the ISOs do not go on with booting the "active"
partition but rather hop onto the El Torito boot image programs in the ISO.
The Legacy BIOS Bootable bit of GPT is explicitely not an EFI boot
indicator. UEFI 2.4 says in table 20 : "UEFI boot manager (see chapter 3)
must ignore this bit when selecting a UEFI-compliant application".
The BootIndicator byte of MBR partitions is explicitely not for EFI.
Table 14 says: "This field shall not be used by UEFI firmware."
So if "active" partitions are present in GRUB or SYSLINUX equipped ISOs
they are under no circumstances intended for being booted.
Currently debian ISOs for arm64 have no "active" partition. But that's
an inner implementation detail. E.g. HDD bootable ISOs for x86 do have
the "active"/bootable flag on the ISO 9660 partition out of tradition to
appease mad BIOS implementations.
It is well possible to combine x86 BIOS and arm64 EFI boot equipment
in the same ISO image. So the need for an "active" partition might arise.
Have a nice day :)
Thomas
More information about the U-Boot
mailing list