A detailed walkthrough of porting the Helios microkernel (written in the Hare programming language) to aarch64 for a FOSDEM presentation on a Raspberry Pi 4. The post covers the bootloader implementation: creating a PE32+ EFI-compatible executable via hand-written assembly and linker scripts, setting up page tables for a higher-half kernel memory map, implementing an EFI-based memory allocator, loading the kernel ELF image, initializing the ARM MMU with MAIR/TCR/SCTLR registers, and handling the EL2-to-EL1 exception level transition required on real hardware but not in QEMU.

19m read timeFrom drewdevault.com
Post cover image

Sort: