Add support for RISC-V (rebased)
(Rebased version of https://github.com/au-ts/libvmm/pull/121, new PR due to commit history changes.)
This PR adds initial support for RISC-V guests to libvmm.
Right now, only 64-bit guests are supported/tested.
This PR is a draft as there is still much more work to do and more to test/fix such as multiple vCPUs are more complex example systems, but right now a Linux guest can boot and get into user-space.
This PR will likely not be merged for a while as it depends on changes to seL4, which will require an RFC and code review that typically takes months.
To try out this PR, you will need changes a specific branch of Microkit and seL4:
- Microkit, https://github.com/Ivan-Velickovic/microkit/tree/riscv_he
- seL4, https://github.com/Ivan-Velickovic/seL4/tree/microkit_riscv_he
The simple example works with QEMU virt RISC-V, I am working on getting it working on the SiFive Premier P550.
To get the simple example running on QEMU, run the following command:
cd examples/simple
zig build -Dsdk=<microkit sdk> -Dboard=qemu_virt_riscv64 -Dlinux=board/qemu_virt_riscv64/linux -Dinitrd=board/qemu_virt_riscv64/rootfs.cpio.gz qemu