From ccfbb3f3568552f66059ab67af863dbdb6ee5ba9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Kr=C3=B6ning?= Date: Fri, 25 Aug 2023 17:24:06 +0200 Subject: [PATCH] feat: rename crate to hermit-kernel MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Martin Kröning --- .github/workflows/ci.yml | 14 +++--- .github/workflows/publish_docs.yml | 6 +-- Cargo.lock | 68 +++++++++++++++--------------- Cargo.toml | 6 +-- README.md | 14 +++--- src/arch/aarch64/mm/paging.rs | 2 +- src/macros.rs | 2 +- xtask/src/main.rs | 6 +-- 8 files changed, 59 insertions(+), 59 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0deb7c2201..d03219a149 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,7 +26,7 @@ jobs: - uses: mkroening/rust-toolchain-toml@main - uses: Swatinem/rust-cache@v2 - name: Check each feature - run: cargo hack check --package libhermit-rs --each-feature --no-dev-deps --target x86_64-unknown-none + run: cargo hack check --package hermit-kernel --each-feature --no-dev-deps --target x86_64-unknown-none env: RUSTFLAGS: @@ -67,8 +67,8 @@ jobs: - uses: Swatinem/rust-cache@v2 - name: Check docs run: | - cargo doc --package libhermit-rs --no-deps --document-private-items --target x86_64-unknown-none - cargo doc --package libhermit-rs --no-deps --document-private-items --target aarch64-unknown-none-softfloat --no-default-features + cargo doc --package hermit-kernel --no-deps --document-private-items --target x86_64-unknown-none + cargo doc --package hermit-kernel --no-deps --document-private-items --target aarch64-unknown-none-softfloat --no-default-features build: name: Build @@ -124,9 +124,9 @@ jobs: with: repository: hermitcore/rusty-hermit submodules: true - - name: Remove libhermit-rs submodule + - name: Remove hermit-kernel submodule run: git rm -r libhermit-rs - - name: Checkout libhermit-rs + - name: Checkout hermit-kernel uses: actions/checkout@v3 with: path: libhermit-rs @@ -249,9 +249,9 @@ jobs: with: repository: hermitcore/rusty-hermit submodules: true - - name: Remove libhermit-rs submodule + - name: Remove hermit-kernel submodule run: git rm -r libhermit-rs - - name: Checkout libhermit-rs + - name: Checkout hermit-kernel uses: actions/checkout@v3 with: path: libhermit-rs diff --git a/.github/workflows/publish_docs.yml b/.github/workflows/publish_docs.yml index c0266de059..b43ec856d8 100644 --- a/.github/workflows/publish_docs.yml +++ b/.github/workflows/publish_docs.yml @@ -21,7 +21,7 @@ jobs: sudo apt-get update sudo apt-get install nasm - name: Generate documentation - run: cargo doc --target x86_64-unknown-none --package libhermit-rs + run: cargo doc --target x86_64-unknown-none --package hermit-kernel - name: Generate index.html run: | cat > target/x86_64-unknown-none/doc/index.html < Redirect! - + -

Redirect

+

Redirect

EOL diff --git a/Cargo.lock b/Cargo.lock index bac0855bff..6addc0d7a7 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -283,40 +283,7 @@ dependencies = [ ] [[package]] -name = "hermit-sync" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "645fad6b0a6c72039c4b2741c8f8e82731f47b6773a87b2a74269be8672f9f20" -dependencies = [ - "aarch64-cpu", - "exclusive_cell", - "generic_once_cell", - "lock_api", - "riscv", - "tock-registers", - "x86_64", -] - -[[package]] -name = "include-transformed" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fdd0ac3785f538abb2b8221505e8244726756de924f670d06f4518c9a70a13d" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.28", - "tempfile", -] - -[[package]] -name = "libc" -version = "0.2.147" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4668fb0ea861c1df094127ac5f1da3409a82116a4ba74fca2e58ef927159bb3" - -[[package]] -name = "libhermit-rs" +name = "hermit-kernel" version = "0.6.4" dependencies = [ "aarch64", @@ -355,6 +322,39 @@ dependencies = [ "zerocopy", ] +[[package]] +name = "hermit-sync" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "645fad6b0a6c72039c4b2741c8f8e82731f47b6773a87b2a74269be8672f9f20" +dependencies = [ + "aarch64-cpu", + "exclusive_cell", + "generic_once_cell", + "lock_api", + "riscv", + "tock-registers", + "x86_64", +] + +[[package]] +name = "include-transformed" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fdd0ac3785f538abb2b8221505e8244726756de924f670d06f4518c9a70a13d" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.28", + "tempfile", +] + +[[package]] +name = "libc" +version = "0.2.147" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4668fb0ea861c1df094127ac5f1da3409a82116a4ba74fca2e58ef927159bb3" + [[package]] name = "linux-raw-sys" version = "0.4.5" diff --git a/Cargo.toml b/Cargo.toml index a4b81517a6..7256abe11d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "libhermit-rs" +name = "hermit-kernel" version = "0.6.4" authors = [ "Stefan Lankes ", @@ -16,8 +16,8 @@ license = "MIT OR Apache-2.0" readme = "README.md" keywords = ["unikernel", "libos"] categories = ["os"] -repository = "https://github.com/hermitcore/libhermit-rs" -documentation = "https://hermitcore.github.io/libhermit-rs/hermit/" +repository = "https://github.com/hermitcore/kernel" +documentation = "https://hermitcore.github.io/kernel/hermit/" edition = "2021" description = "A Rust-based library operating system" exclude = [ diff --git a/README.md b/README.md index 76e382436e..bc7fc3851d 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,12 @@ -# RustyHermit: libhermit-rs +# Hermit Kernel -[![Documentation](https://img.shields.io/badge/docs-latest-blue.svg)](https://hermitcore.github.io/libhermit-rs/hermit/) +[![Documentation](https://img.shields.io/badge/docs-latest-blue.svg)](https://hermitcore.github.io/kernel/hermit/) ![License](https://img.shields.io/badge/license-MIT%2FApache--2.0-blue) [![Zulip Badge](https://img.shields.io/badge/chat-hermit-57A37C?logo=zulip)](https://hermit.zulipchat.com/) -_libhermit-rs_ is the kernel of the [RustyHermit](https://github.com/hermitcore/rusty-hermit) unikernel project. +This is the kernel of the [Hermit](https://github.com/hermitcore) unikernel project. ## Requirements @@ -28,11 +28,11 @@ cargo xtask build --arch x86_64 ``` On completion, the script will print the path of `libhermit.a`. -If you want to build _libhermit-rs_ for aarch64, please replace `x86_64` by `aarch64`. +If you want to build the kernel for aarch64, please replace `x86_64` by `aarch64`. ### Control the kernel messages verbosity -_libhermit-rs_ uses the lightweight logging crate [log](https://github.com/rust-lang/log) to print kernel messages. +This kernel uses the lightweight logging crate [log](https://github.com/rust-lang/log) to print kernel messages. The environment variable `HERMIT_LOG_LEVEL_FILTER` controls the verbosity. You can change it by setting it at compile time to a string matching the name of a [LevelFilter](https://docs.rs/log/0.4.8/log/enum.LevelFilter.html). If the variable is not set, or the name doesn't match, then `LevelFilter::Info` is used by default. @@ -43,7 +43,7 @@ $ HERMIT_LOG_LEVEL_FILTER=Debug cargo xtask build --arch x86_64 ## Credits -_libhermit-rs_ is derived from following tutorials and software distributions: +This kernel is derived from following tutorials and software distributions: 1. Philipp Oppermann's [excellent series of blog posts][opp]. 2. Erik Kidd's [toyos-rs][kidd], which is an extension of Philipp Opermann's kernel. @@ -68,5 +68,5 @@ at your option. Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. -libhermit-rs is being developed on [GitHub](https://github.com/hermitcore/libhermit-rs). +The kernel is being developed on [hermitcore/kernel](https://github.com/hermitcore/kernel). Create your own fork, send us a pull request, and chat with us on [Zulip](https://hermit.zulipchat.com/). diff --git a/src/arch/aarch64/mm/paging.rs b/src/arch/aarch64/mm/paging.rs index 4f6ca55011..b531949d9c 100644 --- a/src/arch/aarch64/mm/paging.rs +++ b/src/arch/aarch64/mm/paging.rs @@ -510,7 +510,7 @@ where /// Returns the next subtable for the given page in the page table hierarchy. /// /// Must only be called if a page of this size is mapped in a subtable! - // FIXME: https://github.com/hermitcore/libhermit-rs/issues/771 + // FIXME: https://github.com/hermitcore/hermit-kernel/issues/771 #[allow(clippy::mut_from_ref)] fn subtable(&self, page: Page) -> &mut PageTable { assert!(L::LEVEL < S::MAP_LEVEL); diff --git a/src/macros.rs b/src/macros.rs index 5658b709ad..5d5139bdbc 100644 --- a/src/macros.rs +++ b/src/macros.rs @@ -104,7 +104,7 @@ macro_rules! kernel_function { } // TODO: Properly switch kernel stack with newlib -// https://github.com/hermitcore/libhermit-rs/issues/471 +// https://github.com/hermitcore/hermit-kernel/issues/471 #[cfg(all(target_arch = "x86_64", feature = "newlib"))] macro_rules! kernel_function { ($f:ident($($x:tt)*)) => {{ diff --git a/xtask/src/main.rs b/xtask/src/main.rs index 52d62d8a08..3f8830f1ad 100644 --- a/xtask/src/main.rs +++ b/xtask/src/main.rs @@ -87,7 +87,7 @@ impl flags::Build { .unwrap_or_default(); // TODO: Re-enable mutable-noalias - // https://github.com/hermitcore/libhermit-rs/issues/200 + // https://github.com/hermitcore/hermit-kernel/issues/200 rustflags.push("-Zmutable-noalias=no"); if self.instrument_mcount { @@ -198,7 +198,7 @@ impl flags::Clippy { let sh = sh()?; // TODO: Enable clippy for aarch64 - // https://github.com/hermitcore/libhermit-rs/issues/381 + // https://github.com/hermitcore/hermit-kernel/issues/381 for target in [Arch::X86_64, Arch::AArch64] { let target_args = target.cargo_args(); cmd!(sh, "cargo clippy {target_args...}").run()?; @@ -210,7 +210,7 @@ impl flags::Clippy { .arg("--features=acpi,fsgsbase,pci,smp,vga") .run()?; // TODO: Enable clippy for newlib - // https://github.com/hermitcore/libhermit-rs/issues/470 + // https://github.com/hermitcore/hermit-kernel/issues/470 // cmd!(sh, "cargo clippy {target_args...}") // .arg("--no-default-features") // .arg("--features=acpi,fsgsbase,newlib,smp,vga")