All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- ci: add
check-changlog
andcheck-commit-signatures
inworkflows
. - pmu: add missing
snapshot_set_shmem
function and testcases inPmu
trait. - pmu: add missing
snapshot_set_shmem
function inPmu
trait, impl for&T
andOption<T>
andForward
structure - forward: derive
Copy
,Default
,PartialEq
,Eq
andHash
for struct Forward - pmu: mark that signatures of
pmu_counter_{config_matching, start, stop}
would be changed in RustSBI 0.5.0, as they are breaking changes. - lib: re-export
CounterMask
structure fromsbi-spec
crate.
- susp: amend documentation on
system_suspend
function.
- macro based
#[derive(RustSBI)]
interface - support System Suspend extension
- support CPPC extension
- support for NACL and STA extensions
handle_ecall
now only requires&self
since RustSBI trait implementations are internally mutableinto_inner
function forHartMask
- forward extensions to current environment by
Forward
struct
- run on provided
EnvInfo
by default; bare metal M-mode environment should gatemachine
- doc: grammar tweaks in hsm module
- update dependency
sbi-spec
to v0.0.6, usePhysical
struct fromsbi-spec
crate. - merge rustsbi/sbi-{rt, spec, testing} repositories into rustsbi/rustsbi repository.
sbi_2_0
feature; RustSBI now supports SBI 2.0-rc1 by default- support for legacy SBI extensions
- singleton-based RustSBI interface; use derive macro
#[derive(RustSBI)]
instead
0.3.2 - 2023-02-26
Bump RISC-V SBI specification version to 2.0-rc1.
- pmu: counter_fw_read_hi function in SBI 2.0-rc1
- lib: memory address parameters and DBCN extension
- lib: adds feature
sbi_2_0
and gate pmu read_hi
- doc: amend using SBI 2.0-rc1 specification
impl<T: Console> Console for &T
0.3.1 - 2023-01-20
- Update dependency crate
riscv
to version 0.10.1 - Use let-else to simplify code, bump MSRV to 1.65.0
0.3.0 - 2022-11-03
- Instance based and/or machine independent RustSBI to support hypervisor development
- Structure
MachineInfo
for non-machine environment, e.g. cross-architecture emulator - Builder structure for instance based RustSBI framework
- Implement RustSBI traits for their references
- Extensive documents for hypervisors, emulators, and machine environments using RustSBI
- Feature
legacy
to gate the SBI legacy extension - Expose
init_*
functions on instance-based RustSBI implementation - LEGACY_CLEAR_IPI implemented
- Probe function now returns if legacy extensions are available
- Update to
riscv
crate 0.9.0, sbi-spec crate version 0.0.4 - Rename
send_ipi_many
tosend_ipi
- Remove dependency on crate alloc; RustSBI now works without a heap
- Remove embedded-hal serial adapter to legacy console
0.2.2 - 2022-03-23
This update adapts to ratified RISC-V SBI v1.0.0 specification, it's recommended for users to update to the latest RustSBI version.
- Support for RISC-V SBI v1.0.0 Ratified Specification
- Internal guest and instance module
- Use the Rust 2021 edition
- Update dependency
embedded-hal
to v0.2.7
0.2.1 - 2022-02-14
This update fixes a severe bug on IPI module. The previous version of RustSBI did not follow the SBI definition of IPI module on SBI v0.3 format. Users are encouraged to use 0.2.1 and newer version instead of yanked 0.2.0 version.
- Internal speed up to new SBI v0.3+ IPI procedure
- Reduce code size by inlining internal functions
- Severe bug on IPI does not follow the new SBI version convention rule
- Pass cargo test on docs, add test cases on hart mask
0.2.0 - 2022-02-13
- Support for RISC-V SBI v1.0 and v0.3 Specification
- S-level Illegal instruction exception is now delegated into S-level software handler
- Support RFENCE extension in RustSBI framework
- Added a test kernel to test SBI function on RustSBI implementations
- Support device tree binary in the K210 platform
- Support SBI v0.3 hart suspend function
- Support PMU extension trait and init function
- Use fat pointer cell to support asynchronous hart state monitor module
- Build under new asm! macro
- Reform RustSBI project into a library
- Use
u32
function and module id width for SBI 1.0 - Function
rustsbi::ecall
now requirea0
-a5
input parameters - Enhanced in-line code documents from the SBI standard
- Now IPI module requires to return an
SbiRet
value - Remove use of
global_asm
andllvm_asm
in test kernel - Align to 4 bytes for interrupt handler on QEMU and test kernel
- Update
riscv
crate dependency for QEMU platform - Use
mtval
to read instruction on QEMU; still need to be kept on K210 as 1.9.1 does not define this register behavior - Modify second parameter of
enter_privileged
toopaque
other thandtb_pa
- Dump all trap frame registers when exception happened in reference implementations
- Use
embedded-hal
dependency version0.2.6
- Change to asynchronous lock structure trait style
- Function
num_counters
returnsusize
and its SBI call must returnSbiRet::success()
- Use amo mutex for legacy stdio handler; remove dependency on
lazy_static
andspin
- Improve documents to adapt to v1.0-rc2 specification
- Test kernel console now will lock before
println
line is finished - Non-legacy supervisor IPI extension is fixed
- Returns -1 other than 0 when legacy console getchar function fails; thanks to @duskmoon314
0.1.1 - 2021-02-01
- Abstract support for HSM and SRST extensions
- Support SRST extension using the test device on QEMU
- Count harts from device tree binary on QEMU platform
- Show hart id on panic for QEMU platform
- Use '#[naked]' instead of global assembly in newer Rust versions for RustSBI platforms
- Fix
init_hsm
function which is not exported before - Small fixes on library documents
0.1.0 - 2020-12-26
RustSBI is adapted to the SBI standard with implementation number 4.
- Implementation specific SBI module
0x0A000004
defined - K210 specific sbi_rustsbi_k210_sext SBI call
- Update private SBI function to K210 implementation
- Delegate instruction load/store faults to S mode, allowing legacy console getchar to work on K210 (#7).
- Fixed 64-bit and 32-bit instruction value for target pointer widths
- Fixed readme document path for crates.io
0.0.2 - 2020-10-20
- Support for Kendryte K210 with MMU and S-Mode
- Support for QEMU
- SBI v0.2 TIME extension and IPI extension
- RISC-V ISA both RV32 and RV64
- RISC-V Privileged Specification v1.11
- Backward compatible to privileged spec v1.9.1