ahrightos-kernel 0.1.0

RISC-V 64 Rust teaching kernel for AhRightOS.
Documentation

ahrightos-kernel

ahrightos-kernel is the executable RISC-V 64 teaching kernel for AhRightOS. The library crate is named os for compatibility with the existing boot code and integration tests, while the package name is crates.io-ready and specific to the project.

The kernel runs on QEMU virt with OpenSBI and consumes reusable component crates from the workspace:

flowchart TD
    Kernel[ahrightos-kernel bin: os] --> Lib[os library facade]
    Lib --> Memory[ahrightos-memory]
    Lib --> Process[ahrightos-process]
    Lib --> FS[ahrightos-fs]
    Lib --> Riscv[RISC-V trap / QEMU glue]
    Kernel --> QEMU[QEMU virt + OpenSBI]

Verification

Run host component tests from AhRightOS-src/:

cargo test --workspace --exclude ahrightos-kernel

Run kernel unit/build/system tests from AhRightOS-src/:

cargo build -p ahrightos-kernel --target riscv64imac-unknown-none-elf
cargo test -p ahrightos-kernel --target riscv64imac-unknown-none-elf --lib
cargo test -p ahrightos-kernel --target riscv64imac-unknown-none-elf --test basic_boot
cargo test -p ahrightos-kernel --target riscv64imac-unknown-none-elf --test heap_allocation
cargo test -p ahrightos-kernel --target riscv64imac-unknown-none-elf --test should_panic
cargo test -p ahrightos-kernel --target riscv64imac-unknown-none-elf --test risk_regressions

Run the release-readiness gate:

./scripts/verify_crates_release.sh

The reusable crates can be verified with cargo package directly. The kernel package depends on those crates by path + version; after ahrightos-memory, ahrightos-process, and ahrightos-fs are published, run AHRIGHTOS_VERIFY_KERNEL_PUBLISH=1 ./scripts/verify_crates_release.sh for the final kernel cargo package verification.