dgilmore changed the topic of #fedora-riscv to: Fedora on RISC-V https://fedoraproject.org/wiki/Architectures/RISC-V || Logs: https://libera.irclog.whitequark.org/fedora-riscv || Alt Arch discussions are welcome in #fedora-alt-arches
davidlt has joined #fedora-riscv
davidlt has quit [Ping timeout: 244 seconds]
davidlt has joined #fedora-riscv
jednorozec has quit [Ping timeout: 246 seconds]
zsun has joined #fedora-riscv
jednorozec has joined #fedora-riscv
zsun has quit [Quit: Leaving.]
<davidlt> rwmjones, I finally sent the email.
<davidlt> I CC'ed a bunch of folks that somehow are related or are interested in this.
<davidlt> oh, it bounced from rharwood email.
<javierm> davidlt: rharwood left RH a few months ago
<davidlt> I direct booted Fedora kernel + initrd with EDK2 firmware. The firmware was built by me, and Linux side bits came from Pungi compose already.
<davidlt> javierm, that explains it. I saw somewhat recent commits (~6 months ago), and I assume that's "recent enough".
<javierm> davidlt: nfrayer and pjones are the folks you should contact for boot stack related stuff
<davidlt> Simply, I think, almost (if not all) bits are in place for riscv64.
<davidlt> and we probably want to have it before riscv64 becomes part of the official arches in Fedora.
<davidlt> (and I really don't want to do those massive rebases myself)
<javierm> davidlt: ah, you already Cc them. I also got your email :)
<davidlt> javierm, I added a bunch of folks that are related or showed interest in it
<javierm> cool
<davidlt> I think edk2 update alone would allow to progress further with Pungi
<davidlt> because oz does direct boot (which works!), tested locally.
<davidlt> I am recompiling the last kernel with ZBOOT EFI support
<davidlt> I also need to update QEMU to 8.1 for this to work
<javierm> davidlt: cool, is the EFI zboot decompress platform agnostic?
<davidlt> Or in other words no updates on Pungi side until a few (large) bits get updated
<javierm> or do you need som riscv specific code?
<davidlt> Yes, but it depends on UEFI firmware
<davidlt> It's generic
<davidlt> GRUB 2.12 also adds a generic header and loader for ARM, ARM64 and RISCV.
<javierm> ah, I see
<javierm> because we have https://src.fedoraproject.org/rpms/unzboot if that's not the case
<javierm> we use it for Chromebook for example that ship with Coreboot (that doesn't support PE/COFF binaries)
<davidlt> RISCV doesn't have self-uncompressing kernels as x86_64
<javierm> yeah I know, nor has aarch64
<davidlt> On the board it's U-Boot that has to uncompress it before jumping to it
<davidlt> Atish added support for U-Boot to uncompress kernels.
<davidlt> EFI_ZBOOT is a generic thing, but again depends on UEFI.
<davidlt> aarch64 kernels already switched to it.
<javierm> davidlt: what I meant is that you don't need EFI to boot Fedora kernel images that are built as EFI binaries
<javierm> because for backward compat, the vmlinuz is stored in a section and could be extracted
<davidlt> In the current setup Pungi failed as it attempted to boot compressed kernel.
<javierm> that unzboot tool could be used to extract the vmlinuz from the EFI binary
<davidlt> So again, U-Boot does that. It uncompressed that after loading it from /boot.
<davidlt> Where does unzboot fits in the bootchain?
<javierm> davidlt: during kernel-install, you can have a /lib/kernel/install.d/ that extracts the vmlinuz from the PE binary and copies it to the /boot dir
<davidlt> In that case I should just ship uncompressed kernel :)
<davidlt> (that would make life a lot easier)
<javierm> davidlt: yeah, but the fedora kernel package builds that unconditionally
<davidlt> Not really, the target is per arch
<davidlt> We used to build those uncompressed X years ago
<davidlt> If I would go with uncompressed kernel the Pungi would go further (and there is no need for EDK2)
<javierm> yeah, is per arch but what I meant is that doesn't ship both types of kernel images
<javierm> you either enable it for riscv or not
<davidlt> Yes
<javierm> so the more generic option seems to be to enable it and extract in platforms that don't support it
<javierm> rather than restricting to vmlinuz for platforms that don't have EFI support
<davidlt> Well all platforms that we support should be able to do it
<davidlt> U-Boot provides EFI
<javierm> that's better then, yeah
<davidlt> We always had EFI from day 1 IIRC
<davidlt> And technically CONFIG_EFI_ZBOOT should work.
<javierm> cool
<davidlt> Just in case I checked that required EFI calls exist in U-Boot (well, a quick grep and few checks in the headers)
<javierm> the most standard the boot path the better indeed
<davidlt> and again, aarch64 is already running with it, and most targets there are U-Boot based.
<javierm> yeah, Chromebooks are the only exception sadly
<davidlt> at this point we should be able to do exact same as x86_64 and aarch64 (assuming we update all the relevant packages).
<davidlt> Thankfully there are no RISCV chromeboosk (yet) ;)
<javierm> :)
<davidlt> javierm, why unzboot doesn't have sub-package with install.d script?
<javierm> need to better integrate Chromebook support in fedora but for now eballetbo just keep it in an install script
<davidlt> These days I would probably go with Apple laptop for aarch64 instead of a Chromebook
<javierm> davidlt: agreed
<javierm> and since they are using u-boot AFAIU, you have EFI boot too
zsun has joined #fedora-riscv
<rwmjones> davidlt: oh yeah, I saw the email, thanks!
* rwmjones is currently rereading the RISC-V user spec
<davidlt> Yeah, that's P870 Hot Chips slides
<davidlt> rwmjones, I actually forgot to CC Gerd Hoffmann <kraxel@redhat.com> on edk2 package :/
zsun has quit [Quit: Leaving.]
<dgilmore> davidlt: there is no real fedora support for Chromeboks, the lack of legacy bios and supportable bootpath makes it next to impossible to support
<dgilmore> the EFI support in u-boot should work fine on RISC-V
<dgilmore> decompressing the kernel is one thing
davidlt has quit [Ping timeout: 255 seconds]
drewfustini_ has joined #fedora-riscv
drewfustini has quit [Ping timeout: 246 seconds]
drewfustini_ is now known as drewfustini
leah2 has quit [Ping timeout: 246 seconds]
leah2 has joined #fedora-riscv