{"id":13579327,"url":"https://github.com/rustsbi/rustsbi","last_synced_at":"2025-05-13T21:09:35.095Z","repository":{"id":38679660,"uuid":"278593354","full_name":"rustsbi/rustsbi","owner":"rustsbi","description":"RISC-V Supervisor Binary Interface (RISC-V SBI) library in Rust; runs on M or HS mode; good support for embedded Rust ecosystem. For binary download see prototyper folder.","archived":false,"fork":false,"pushed_at":"2025-04-22T13:19:46.000Z","size":1179,"stargazers_count":1148,"open_issues_count":7,"forks_count":112,"subscribers_count":21,"default_branch":"main","last_synced_at":"2025-04-22T14:25:49.091Z","etag":null,"topics":["bare-metal","riscv","rust","rust-embedded","rustsbi","sbi","sbi-specification"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rustsbi.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE-MIT","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-07-10T09:26:56.000Z","updated_at":"2025-04-22T13:19:49.000Z","dependencies_parsed_at":"2024-02-07T04:37:12.719Z","dependency_job_id":"2e485b5f-6a1f-4213-8919-a522f5d60e3d","html_url":"https://github.com/rustsbi/rustsbi","commit_stats":{"total_commits":331,"total_committers":10,"mean_commits":33.1,"dds":0.1570996978851964,"last_synced_commit":"16bc39b34a37eb8bf69aedb3cc0a8465e2f03dbf"},"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rustsbi%2Frustsbi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rustsbi%2Frustsbi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rustsbi%2Frustsbi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rustsbi%2Frustsbi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rustsbi","download_url":"https://codeload.github.com/rustsbi/rustsbi/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251561040,"owners_count":21609308,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bare-metal","riscv","rust","rust-embedded","rustsbi","sbi","sbi-specification"],"created_at":"2024-08-01T15:01:38.403Z","updated_at":"2025-04-29T18:36:02.537Z","avatar_url":"https://github.com/rustsbi.png","language":"Rust","readme":"# RustSBI\n\nRISC-V Supervisor Binary Interface ([SBI](https://github.com/riscv-non-isa/riscv-sbi-doc/)) library in Rust; runs on M-mode or HS mode.\n\n[![crates.io](https://img.shields.io/crates/v/rustsbi.svg)](https://crates.io/crates/rustsbi)\n[![Documentation](https://docs.rs/rustsbi/badge.svg)](https://docs.rs/rustsbi)\n![License](https://img.shields.io/crates/l/rustsbi.svg)\n\n## Binary downloads\n\nMost users would get RustSBI binary download from the RustSBI Prototyper. Check out the documents [here](https://github.com/rustsbi/rustsbi/tree/main/prototyper)\nto build or download images for supported platforms.\n\nBoards, SoC vendors and research groups may sometimes provide dedicated RustSBI package for supported platforms.\nThere are packages exists on [awesome-rustsbi](https://github.com/rustsbi/awesome-rustsbi): it is a curated list of\nawesome things related to RustSBI, which includes some implementation projects maintained by individuals or the community.\n\nUsers on commercial boards may visit implementation specific distribution links depending on the platforms they need,\nor consult vendors if they provide discrete RustSBI package support.\n\n## Minimum supported Rust version\n\nTo compile RustSBI library, you need at least nightly Rust version of `rustc 1.88.0-nightly (d6c1e454a 2025-04-21)`.\nWe are going to target stable Rustc once version 1.88.0 is landed (on 2025-06-25).\n\n## Build this project\n\n### For firmware user\n\nIf you need to build RustSBI firmware for M-mode, please refer to the [RustSBI Prototyper](prototyper/README.md) documentation.\n\n### For library user\n\nRustSBI is usually used as a library or dependency. If you wish to, you may build RustSBI library itself using the\nfollowing command:\n\n```bash\ncargo build\n```\n\nThe build should finish without any errors.\n\nBuilding under native platform will allow development of hypervisors and emulators.\nTo cross-build for a RISC-V platform environment, you may install the target and build onto it instead:\n\n```bash\n# If you don't have the cross compile target installed, install it first\nrustup target add riscv64imac-unknown-none-elf\n# Build this project as library\ncargo build --target riscv64imac-unknown-none-elf\n```\n\nThe target platform of RISC-V platform firmware is usually a bare metal target.\nUnder normal circumstances these targets in Rust would start with `riscv??-` and end with `-none-elf`.\n\n## Features\n\n- Feature rich and extensible operating system runtime\n- Empower support, compatibility for machines, hypervisors and emulators\n- Support to and develop with RISC-V SBI specification v2.0 ratified\n- Written in Rust, builds under stable Rust\n- Capable to develop with other firmware ecosystem projects\n- Adapted for operating system kernel models on your choice\n- Included a LLM based Agent module called RustSBI Agent (https://github.com/rustsbi/Agent), which is designed to assist system software developers in their development process\n\n## Frequently asked questions\n\n1. How would I build a RustSBI implementation?\n\nRustSBI have extensive documents on such purposes! No matter what you are building with it, you will find some\ndocuments about RustSBI on bare-metal environments, hypervisors and emulators.\n\nCheck it out at [RustSBI document main page](https://docs.rs/rustsbi).\n\n2. Can I use RustSBI on C based kernels?\n\nYes, you can! RustSBI strictly follows RISC-V SBI standard. All features are prepares for all programming languages,\nas long as they support RISC-V SBI defined calling convention.\n\nIf your kernel language supports other SBI implementations, usually it will support RustSBI in the same way.\n\n## Talks and documents\n\nThis project is originally a part of rCore Summer of Code 2020 activities, inspired\nby [MeowSBI](https://github.com/meow-chip/MeowSBI) and other similar projects. Now it is capable of running\nrCore-Tutorial and other OS kernels on wide supported RISC-V devices.\n\nThere are multiple talks related to RustSBI dated back to Aug 2020. These talks discuss from design and abstraction of\nRustSBI modules, to actual production and research usage scenario related to RustSBI and RISC-V bootloaders. Public\nslides and blog articles of these talks are available at [RustSBI/slides](https://github.com/rustsbi/slides) page.\n\n## Notes on platform implementation\n\n1. RustSBI should be used as a library. Under normal circumstances, RustSBI platform can be implemented\n   with embedded Rust's `embedded-hal` libraries.\n2. Contributions are welcomed! We welcome to implement and test RustSBI for both FPGA cores and real cores.\n   Implementations for emulators are also welcomed. If you are ready, start your own binary project and use\n   RustSBI in it!\n3. If there is a bug in RustSBI project itself, fire an issue or pull request to let us know!\n\n## License \u0026 Copyright\n\nThis project is licensed under either of\n\n- MIT license ([LICENSE-MIT](LICENSE-MIT) or [http://opensource.org/licenses/MIT](http://opensource.org/licenses/MIT))\n- Mulan PSL v2 ([LICENSE-MULAN](LICENSE-MULAN) or [https://opensource.org/licenses/MulanPSL-2.0](https://opensource.org/licenses/MulanPSL-2.0))\n\nDocuments from RISC-V SBI Specification are used in this project. These documents are (C) RISC-V Foundation under\nCreative Commons Attribution 4.0 International License (CC-BY 4.0). The full license text is available\nat https://creativecommons.org/licenses/by/4.0/.\n","funding_links":[],"categories":["Rust","Uncategorized","CPU RISC-V","General Operating System"],"sub_categories":["Uncategorized","网络服务_其他"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frustsbi%2Frustsbi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frustsbi%2Frustsbi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frustsbi%2Frustsbi/lists"}