anyway, edk2 could basically be used like grub
you can already do this in the shell for example:
fs0:
linux.efi root=/dev/sda1 rw iomem=relaxed
...simple example, but you can compile what's called a "uki" (unified kernel image) with userland and everything - and you could kexec another kernel (or just have that as your kernel)
yes, edk2 has no understanding of what "linux" is, but it can pass arguments to programs when calling them from the shell. so: you wrap linux in efi. that's the point of a uki
doing this, you can replace grub basically. libreboot adds a bunch of linux filesystems to edk2 - all it needs now is e.g. mdraid, dmcrypt and lvm support for instance. you could totally make something custom with it
if you had encrypted esp, linux file ssytem inside, obviously that's not part of usual efi spec (spec is fat32), but you can see here how powerful this might be
that's my vision for libreboot edk2 in future releases. absolutely extend edk2 and make it a linux-first setup
combined that with user-enrolled secureboot and flash lockdown, and a bunch of other things
the mind boggles. and those are my visions. i start with recent work as boring uefi with a few filesystems added - but i'm going to heavily expand it. i'm not simply gcoing to use the spec. it will obviously still do the usual spec (like, it'll boot windows for example, if you want, and i so don't care about windows)
there's a stigma against uefi in the free software world, rightly deserved because proprietary vendors use it as a yoke against free software - the whole thing about secureboot and distros, the extortion that is making distros pay to sign their bootloaders with... microsoft keys. but uefi is an open spec
that's vendor efi. libreboot is completely unrestricted. what i envision basically is a bunch of aggressive extensions to efi spec, by virtue of libreboot's integration and patching, to make it much more powerful for free operating systems
the whole point of efi is it's hackable