Running riscv64 on qemu with the virt machine.
kernel
is a simple elf program that expects to start in supervisor mode,
sets up pages tables and some interrupt handlers and then runs a "program" in user mode.
When I run it with opensbi as the bios (fw_jump.efl
), which jumps to
the address 0x80200000, the code runs as expected. The code is put at that
address with -device loader
When I run it with opensbi jumping to u-boot, which then loads the same code
(packaged into a u-boot image with the script shown), like bootm 0x9000000 - 0x82200000
it still runs as expected but it is much much slower.