VisionFive 2 devel kexec backport
Created by: orangecms
These are backports of kexec-related patches to enable LinuxBoot in the 5.15.0 based kernel fork for the VisionFive 2, taken from Linux 6.3.0-rc3. That allows for booting from NVMe without involving an SD card.
Once the PCIe patches are ported over to the upstream kernel, it can be used directly.
PoC screenshot is here: https://twitter.com/OrangeCMS/status/1640083580888948738
For the full flow, build u-root with core
and boot
templates, add it to Linux as an xz-compressed initramfs, shrink the kernel down by disabling most drivers (e.g., networking and graphics), and use the localboot
command. Then use it with U-Boot SPL + OpenSBI in flash.
Remember to configure OpenSBI to pass on the right DTB to Linux.
Note: Omit U-Boot proper; that is replaced by the Linux image.
I recommend placing a BLS config on the NVMe together with any distros desired.
This also includes a Linux defconfig for convenient use with cpu
, which is close to the config suitable for the LinuxBoot described above.