Note: This project is just started and is WIP! Please use a VM for testing.
RustyBoot-RISC-V is a minimalist, modular bootloader for RISC-V platforms, inspired by the original RustyBoot UEFI bootloader for x86. It aims to provide a flexible foundation for loading RISC-V kernels directly from block devices with support for MBR/GPT partition tables and EXT2/3/4 filesystems.
Implemented
- Bare-Metal RISCV
_start()entry point - UART driver for early debug output
- Minimal ELF kernel loader
- Bootloader skeleton structure
- Basic VirtIO for QEMU
Planned
- Memory manager with frame allocator
- MBR/GPT partitioning parsing
- EXT2/3/4 filesystem support
- kernel loading from disk
- Rust nightly with
cargo-xbuild rustup target add riscv64imac-unknown-none-elf- QEMU for RISC-V emulation (optional for testing)
# Build the bootloader
cargo build -Zbuild-std=core,compiler_builtinsqemu-system-riscv64 \
-machine virt \
-nographic \
-bios none \
-kernel target/riscv64imac-unknown-none-elf/debug/rustyboot-riscv \
-serial mon:stdio-You should see UART output in the terminal indicating boot progress.
RustyBoot-RISCV/
├── src/
│ ├── main.rs
│ ├── panic.rs
│ ├── uart/
│ ├── memory/
│ ├── block/
│ ├── fs/
│ └── elf/
├── linker.ld
└── boot/
Contributions are welcome! Please follow the modular structure and maintain no_std compatibility for all bootloader components. Open issues or pull requests for:
-
Device driver improvements
-
Filesystem enhancements
-
Kernel loader optimizations
-
New RISC-V platform support
This project is licensed under the GPLv3 license. See LICENSE for details.