/xernel

Toy kernel written in Rust for x86_64

Primary LanguageRustApache License 2.0Apache-2.0

xernel

A kernel for x86-64 (and maybe ARM/RISC-V later on) using the limine boot protocol. Mostly made for learning purposes, no real-world application.

xernel

Building

For building, you simply need a working Rust installation with the nightly toolchain installed and the mtools package which we use for the generation of the disk image. We use xtask as our workflow for building and running the kernel. Therefore, the command cargo kernel is used.

See cargo kernel help for a list of subcommands and available flags.

You can simply use cargo kernel build or cargo kernel run, it is going to use x86_64 as the default target.

Contact

Feel free to reach out to lockna or mp1310 on Discord or join our Offical Discord Server: https://discord.gg/e3gsmHX4w4

Here you can talk to us in the xernel-development category.

TODO

Things that are still to do:

  • Add doc comments
  • Rewrite mem module
    • Rewrite the page frame allocator so it uses a buddy allocator
    • Rewrite the virtual memory manager, just make it better
    • Switch from linked_list_allocator to a slab allocator for heap
  • Implement a virtual file system
  • Implement a driver system
  • Implement a proper syscall interface
  • Implement a proper userspace
  • Implement a proper init system

Contributing

Contributions to code and documentation are heavily appreciated, may it be a bug fix or an improvement of the existing code or code documentation. New features would be gladly taken over by us, as the project was created for exactly this purpose.

License

xernel is distributed under the terms of either the Apache License (Version 2.0) or the MIT license, at the user's choice. See LICENSE-APACHE and LICENSE-MIT for details. Contributions to the xernel project must be made under the terms of both licenses.