freebsd-dev/stand/efi
Toomas Soome 523a713ffb loader.efi: efipart needs better support detecting nested partitions
Just as disks can have nested partitions, the same happens with cd devices,
so we need to detect device paths and make sure we will not mix the handles.

To address this:

we fetch handle array and create linked list of block devices.
we walk the list and detect parent devices and set children pd_parent.
for {fd, cd, hd}, we walk device list and pick up our devices and store to
corresponding list. We make sure we store parent device first.

For sorting we use 3 steps: We check for floppy, we check for cd and then
everything else must be hd.

In general, it seems the floppy devices have no parent.
CD can have both parents and children (multiple boot entries, partitions
from the hybrid disk image).

Tested by: cross+freebsd@distal.com on Cisco UCS systems, C200 series (C220M5, C240M4).
Also on MBP with UEFI 1.10

Reported by:	Chriss Ross
MFC after:	1w
Differential Revision:	https://reviews.freebsd.org/D22553
2019-11-30 09:11:28 +00:00
..
boot1 Remove duplicate lz4 implementations 2019-11-02 12:28:04 +00:00
fdt stand: refactor overlay loading a little bit 2019-04-11 13:26:28 +00:00
gptboot The efifat files are no longer used: remove the code to build them 2019-09-04 20:55:48 +00:00
include loader.efi: efipart needs better support detecting nested partitions 2019-11-30 09:11:28 +00:00
libefi loader.efi: efipart needs better support detecting nested partitions 2019-11-30 09:11:28 +00:00
loader Remove comment. We're just going to the next node here. 2019-11-28 05:40:10 +00:00
loader_4th Create a loader for each interpreter for x86 BIOS and all EFI 2018-08-14 18:44:41 +00:00
loader_lua Create a loader for each interpreter for x86 BIOS and all EFI 2018-08-14 18:44:41 +00:00
loader_simp Create a loader for each interpreter for x86 BIOS and all EFI 2018-08-14 18:44:41 +00:00
Makefile Create gptboot.efi 2019-06-08 19:02:17 +00:00
Makefile.inc Hoist EFI_TARGET and SOURCE_DATE_EPOCH up into efi/Makefile.inc 2018-07-20 05:18:03 +00:00