Skip to content

Repository files navigation

A9N_header

A9N Microkernel

GitHub Actions Workflow Status Contributor Covenant

LLVM C C++ LLVM

A9N is a Capability-Based Microkernel that supports a variety of hardware platforms through appropriate HAL.
It is implemented with an object-oriented interface, making it easy to use and extend.
It combines high portability, stability, and scalability.

A9N Components list

.
├── src
│   ├── kernel
│   ├── hal
│   │    └── include/hal/interface
│   │    └── {ARCH}
│   ├── liba9n
└── test

src/kernel

The main hardware-independent part of the A9N microkernel.

src/hal

A Hardware Abstraction Layer (HAL) is implemented to provide a portable interface to the underlying hardware.
The {ARCH} directory is referenced during the make process.

src/liba9n

The A9N base library. Used by the kernel, and HAL.

Architecture Status

Currently supported architectures:

  • x86_64 (Long Mode)

Requirements

Kernel

  • LLVM 18 or later
    • Clang
    • Clang++
    • LLVM Config
  • LLD

HAL

x86_64

  • NASM

Build (with Docker)

Syntax

ARCH={target_arch} BUILD_TYPE={Debug|Release} docker compose run --rm a9n-build

Example (x86_64, Release)

ARCH=x86_64 BUILD_TYPE=Release docker compose run --rm a9n-build

Build (with CMake)

mkdir build
cmake -B build -DARCH={target_arch} -DCMAKE_TOOLCHAIN_FILE=./src/hal/{target_arch}/toolchain.cmake -DCMAKE_BUILD_TYPE={Debug|Release}
cmake --build build

Note

Currently, the CMake build supports only the kernel binary.

How to Use

The A9N Microkernel can be custom-configured and automatically configured to suit the needs of a User-space OS.

Custom Build: Assemble and use everything yourself

This method involves configuring and building the kernel, Init, and bootloader separately and then combining them. Currently, we support the following tools for building Init and the following bootloaders.

  • Nun OS Framework is a framework for building Operating Systems based on A9N; Written in Rust.
  • A9NLoader-rs is a bootloader for A9N-based systems (compatible with A9N Boot Protocol x86_64); Written in Rust.

We also provide crates for using the A9N Microkernel, which is utilized internally by the Nun OS Framework, in Rust.

  • a9n-types: Defines the basic types for A9N.
  • a9n_abi: Contains ABI definitions for communicating with the A9N Kernel (e.g., Kernel Calls).

Automatic Configuration: Utilize a convenient runtime (Quick-start)

This is a method to automatically configure and build the kernel, Init, and bootloader. You can build executable binaries as quickly as possible through the ecosystem. SPENCER is an OS ToolKit / Embedded Runtime designed for this purpose. Please refer to the SPENCER project page for details.

Author

horizon2k38 ( Rekka "horizon" IGUMI )

Email : me "at" horizon2k38 "dot" com X : @horizon2k38
Mastodon : @horizon2k38@mstdn.jp
Misskey : @horizon

Acknowledgements

MITOU JR : This project was supported by the MITOU Junior program.

  • @kyasbal : My mentor during the MITOU Junior program, who provided valuable advice.
  • @nuta : Gave me a advice on the implementation.

MITOU IT : This project was supported by the MITOU IT program.

  • @sowawa : My mentor during the MITOU IT program, who provided valuable advice.

And I would also like to thank everyone who supported this project.

License

MIT License

About

Capability-based 3rd-generation Microkernel/Microhypervisor with High-speed IPC Mechanism.

Topics

Resources

Code of conduct

Contributing

Stars

53 stars

Watchers

1 watching

Forks

Releases

Contributors

Languages