How gitcomit8/serix works
Project type and purpose
• This is a bare-metal operating system kernel (“Serix”) written in Rust, booted with the Limine bootloader.
• Its goal is to initialize hardware (CPU, interrupts, memory, console framebuffer) and paint the screen blue on success.
File structure
• Top-level crates (Rust sub-projects) each implement a core kernel subsystem:
• kernel/ – entry point, GDT, syscalls, linker script
• hal/ – CPU, I/O primitives, serial, topology
• idt/ – Interrupt Descriptor Table setup
• apic/ – Local/APIC timer and I/O APIC
• memory/ – Paging, heap allocator
• task/ – async task executor, context switching
• graphics/ – framebuffer console, font rendering
• keyboard/ – keyboard driver
• capability/ – access rights/types store
• util/ – panic handler, helper routines
• Build automation: Makefile builds all crates, assembles an ISO with Limine, and runs QEMU.
• docs/ contains design docs for boot, HAL API, interrupt handling, etc.
README
• Confirms it’s a no-std OS kernel.
• Describes boot flow (Limine ➔ kernel).
• Lists subsystems matching the crates.
Main components & interactions
a. Bootloader (Limine)
– BIOS/UEFI ⇒ loads kernel ELF, hands off control to kernel entry.
b. Kernel entry (kernel/src/main.rs)
– sets up GDT, loads IDT module, calls HAL init.
c. HAL layer
– initializes CPU features, serial port for debugging, I/O primitives, CPU topology.
d. Memory manager
– sets up page tables, enables paging, initializes heap allocator.
e. Interrupt subsystem
– idt module registers handlers; apic configures LAPIC timer & routes IRQs.
f. Task scheduler & async executor
– context switches between tasks, handles wakes/yield.
g. Device drivers
– keyboard driver for PS/2 or USB keyboard input.
h. Graphics console
– writes characters to framebuffer, font lookup, clears screen to blue.
i. Capability & Utility crates
– share types, security primitives, panic handler.
Architectural patterns & principles
• Modular monolithic kernel: subsystems are independent Rust crates.
• Layered boot flow: Limine ➔ kernel core ➔ HAL ➔ subsystems.
• Separation of concerns: memory, CPU, interrupts, devices are decoupled.
• No-std environment: no OS dependencies, direct hardware access.