Fit images and EFI_LOAD_FILE2_PROTOCOL

François Ozog francois.ozog at linaro.org
Sat Oct 3 13:14:39 CEST 2020


Le sam. 3 oct. 2020 à 10:51, Heinrich Schuchardt <xypron.glpk at gmx.de> a
écrit :

> Hello Ilias, hello Christian,
>
>
>
> with commit ec80b4735a59 ("efi_loader: Implement FileLoad2 for initramfs
>
> loading") Ilias provided the possibility to specify a device path
>
> (CONFIG_EFI_INITRD_FILESPEC) from which an initial RAM disk can be
>
> served via the EFI_FILE_LOAD2_PROTOCOL.
>
>
>
> Ard extended the Linux EFI stub to allow loading the initial RAM disk
>
> via the EFI_FILE_LOAD2_PROTOCOL with the utmost priority.
>
>
>
> With commit ecc7fdaa9ef1 ("bootm: Add a bootm command for type
>
> IH_OS_EFI") Cristian enabled signed FIT images that contain a device
>
> tree and a UEFI binary (enabled by CONFIG_BOOTM_EFI=y).
>
>
>
> In the DTE calls we have discussed that it is unfortunate that we do not
>
> have a method to validate initial RAM images in the UEFI context.
>
>
>
> To me it would look like a good path forward to combine the two ideas:
>
>
>
> * Let the signed FIT image (of type IH_OS_EFI) contain a RAM disk
>
> * Pass location and size to the UEFI subsystem and serve them via
>
>   the EFI_FILE_LOAD2_PROTOCOL.
>
>
>
> We could also extend the bootefi command to be callable as
>
>
>
>    bootefi $kernel_addr_r $ramdisk_addr_r:$filesize $fdt_addr_r
>
>
>
> like the booti command to serve an initial RAM disk.
>
>
>
> What are your thoughts?

that looks super interesting.
I propose something (in the latest desk preparing oct 14th) similar except
the an efi application boots the FIT.
I view UEFI as booting a PE coff and pass a set of config tables. Today we
have DTB, we could just add Initrd (you command line). Bootefi would be
responsible to valide the containing FIT before pushing initrd (and
dTB?)into the table. It would be the responsibility of the efi stub to get
the initrd from the config table (GUID to be defined).


>
>
>
> Best regards
>
>
>
> Heinrich
>
> --
François-Frédéric Ozog | *Director Linaro Edge & Fog Computing Group*
T: +33.67221.6485
francois.ozog at linaro.org | Skype: ffozog


More information about the U-Boot mailing list