This article explores booting the Apache NuttX Real-Time Operating System (RTOS) on a 64-bit RISC-V device using the QEMU emulator. The article delves into the RISC-V boot code in NuttX, which includes fetching the CPU ID, disabling interrupts, loading the interrupt vector, and jumping to the start. The author offers a step-by-step guide to building and compiling NuttX for 64-bit RISC-V, as well as an appendix with useful commands and GCC options. The article also highlights NuttX’s compatibility with many devices, from 8-bit to 64-bit, and compares NuttX to a small version of Linux.
https://lupyuen.codeberg.page/articles/riscv.html