Current release: 0.0.4

A hobby operating system kernel written in C and Assembly, targeting x86-64 architecture. The ultimate goal is to run Doom in userland! ๐ฏ
If you are tracking the steps toward a usable shell, see Road to Shell Readiness for the current checklist.
MeniOS has made significant progress with core kernel functionality now solidly implemented. The system boots with Limine bootloader and provides:
- โ Memory Management: Physical memory mapping, virtual memory allocation, and kernel heap management (Issues #35, #57)
- โ Process Scheduling: Preemptive userland scheduler with kernel threads and time slicing (Issue #34)
- โ Synchronization: Blocking mutexes, condition variables, semaphores, and read-write locks with scheduler integration (Issues #36, #37, #39, #40)
- Console System: ANSI escape sequence support with scrolling and color output
- Input/Output: PS/2 keyboard driver with buffered input
- Debugging: Page fault and GPF handlers for system diagnostics
- Testing: Unit test framework using Unity for kernel components
- Privilege Setup: Ring 3 GDT selectors, 64-bit TSS, and user-mode entry trampoline
- Syscalls: INT 0x80 dispatcher with initial
write(1, โฆ)
andexit(status)
support - User Demo: Kernel launches Ring 3 thread with ELF loader exercising full syscall path
- Memory Protection: Kernel/user separation with per-process page tables
With the strong foundation now in place, the next high-priority developments are:
- File Descriptor Management (Issue #96) - Foundation for all I/O operations
- Memory Mapping Syscalls (Issue #89) - mmap/munmap for userspace allocators
- Fork/Exec Process Creation (Issue #93) - Full process lifecycle management
- Threading Support (Issues #108-#113) - Complete multithreading infrastructure
- Advanced IPC (Issues #102-#107) - Pipes, signals, shared memory, and microkernel IPC
A complete threading roadmap has been designed with 6 new issues:
- #108: Kernel threading infrastructure
- #109: pthread API and POSIX threading support
- #110: Thread-safe C library (libc)
- #111: Advanced pthread synchronization primitives
- #112: Thread debugging and profiling support
- #113: Thread-aware system calls and kernel integration
Linux:
- gcc
- ld
- make
- qemu
MacOS:
- Docker
- make
- qemu
make build run
This will build the kernel, create a bootable image, and launch it in QEMU.
All generated artifacts now live under build/
(build/bin
for boot assets, build/obj
for intermediates), keeping the repository tree clean. When the kernel reaches halt()
the QEMU instance exits automatically via the debug-exit device, so make run
returns to your shell without manual intervention. The default QEMU_OPTS
wire an AHCI controller (-device ahci
) with the disk attached to ahci.0
, ensuring the kernel exercises its SATA/AHCI path during every run.
During boot, meniOS schedules the embedded user_demo
ELF immediately after hardware probing. The program now:
- forces the stack to grow across an 8 KiB boundary (exercising lazy stack paging),
- emits three
write(1, โฆ)
syscalls with status messages, and - exits with status 42 via
SYS_exit
.
Expect the log to show the [user_demo]
messages on screen and in com1.log
, confirming that the INT 0x80 path, lazy stack allocation, and non-zero exit codes work. If you need quieter serial output, toggle the verbose syscall traces in src/kernel/syscall/syscall.c
(search for serial_printf
inside syscall_write_handler
).
- Foundation Complete: Memory management, scheduling, and synchronization (Issues #34, #35, #36, #40, #57)
- Integration with Limine bootloader v10
- Physical memory mapping and management with virtual memory allocation
- Kernel malloc implementation with heap management
- Preemptive scheduler with kernel threads and time slicing
- Mutex implementation with blocking and scheduler integration
- Condition variables for advanced synchronization
- ANSI console with scrolling and color support
- Complete vsprintk function with all format specifiers
- PS/2 keyboard driver with proper input handling
- Virtual-to-physical address translation (page table walking)
- Ring 3 user mode infrastructure with syscall interface
- ELF loader for user programs
- Per-process virtual memory with kernel/user separation
- Kernel block device abstraction layer (Issue #114)
- SATA/AHCI DMA block driver with interrupt completion (Issue #62)
- DMA-friendly allocation helpers (Issue #115)
- Global block cache for block devices (Issue #63)
- Kernel VFS layer backed by FAT32 filesystem (Issue #65)
- GPT-aware FAT32 filesystem mounting and file access (Issue #64)
- Filesystem syscalls (
open
/read
/write
/lseek
/close
) (Issue #60)
- File descriptor management and pipes (Issue #96)
- Stdin routed through descriptor table for interactive user input
- Memory mapping syscalls (mmap/munmap) (Issue #89) - Enabled by completed VM work
- Kernel threading infrastructure (Issue #108)
- Fork/exec process creation (Issue #93) - Enabled by VM and file descriptor work
- Threading Support: Complete pthread API and multithreading (Issues #108-#113)
- Advanced IPC: Signals, shared memory, microkernel IPC (Issues #102-#107)
- Filesystem: Block cache and write support (Issues #60, #63)
- Networking: Complete TCP/IP stack (Issues #67-#73)
- Graphics: Framebuffer interface and input subsystem (Issues #31-#33)
Foundation โ COMPLETE: The core kernel infrastructure needed for userspace applications is now solid!
Remaining major components for Doom:
- File System: VFS layer, write support, file I/O syscalls
- Graphics: Framebuffer interface, double buffering, palette control
- Input: Userspace keyboard/mouse drivers and event system
- Audio: PCM output, mixing, streaming syscalls
- Toolchain: Cross-compiler, libc subset, build system
See road_to_doom.md
for the complete roadmap and tasks.json
for detailed task tracking.
๐ Progress Assessment: With 5 major foundation issues completed and 64 remaining issues, meniOS is now positioned for rapid feature development. The completed memory management and synchronization work enables parallel development of process management, threading, and I/O systems.
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ USERLAND (In Development) โ
โ โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โ
โ โ Doom โ โ Shell โ โ Games โ โ Applications โ โ
โ โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โ
โ โ โ
โ โโโโโโโโโโโ โ
โ โ libc โ (Threading Support) โ
โ โโโโโโโโโโโ โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Syscall Interface โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ KERNEL SPACE โ
โ
โ โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโ โ
โ โ Process Mgmt โ
โ โ Memory Mgmt โ
โ โ I/O Subsys โ โ
โ โ โข Scheduler โ
โ โ โข Virtual Mem โ
โ โ โข Console โ
โ โ
โ โ โข Kernel Threadsโ โ โข Physical Mem โ
โ โ โข PS/2 Input โ โ
โ โ โข Sync Prims โ
โ โ โข Page Tables โ
โ โ โข Framebufferโ โ
โ โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโ โ
โ โ โ
โ โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโ โ
โ โ Debug/Diag โ โ File System โ โ Hardware โ โ
โ โ โข Page Faults โ
โ โ โข VFS (Planned) โ โ โข Interrupts โ โ
โ โ โข GPF Handler โ
โ โ โข Block Drivers โ โ โข Timers โ โ
โ โ โข Unit Tests โ
โ โ โข File I/O โ โ โข Hardware โ โ
โ โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโ โ
โ โ
โ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โ
โ โ ๐ Threading Support (Planned) โ โ
โ โ โข Kernel threading infrastructure (#108) โ โ
โ โ โข pthread API (#109) โข Thread-safe libc (#110) โ โ
โ โ โข Advanced synchronization (#111) โข Debugging (#112) โ โ
โ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Hardware Abstraction
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ HARDWARE โ
โ CPU โ RAM โ Storage โ Graphics โ Input โ
โ x86-64 โ 4GB+ โ Disk โ VGA โ PS/2 โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
- Filesystem: Read-only FAT32 and tmpfs support exist; write support and broader FS coverage are still TODO (Issues #60, #62-#65).
- Limited hardware support: Only basic PS/2 keyboard, VGA framebuffer
- No network stack: No networking capabilities (Issues #67-#73)
- Graphics: Basic framebuffer, no hardware acceleration
- Audio: No audio subsystem implemented yet
- Threading: Complete multithreading support in development (Issues #108-#113)
- IPC: Advanced inter-process communication planned (Issues #102-#107)
- File I/O: File descriptor management and filesystem support (Issues #96, #60, #62-#65)
- Process Management: Fork/exec and full process lifecycle (Issue #93)
- QEMU only: Primary testing on QEMU emulator, real hardware testing limited
- x86-64 focus: No support for other architectures planned currently
- Development tools: Requires cross-compilation toolchain for full development
src/
- Kernel source code (C and Assembly)include/
- Header filestests/
- Unit tests using Unity frameworkbuild/
- Build artifacts and bootloader assetsdocs/
- Architecture documentation and design decisionstasks.json
- Detailed task tracking with GitHub issue integrationroad_to_doom.md
- Comprehensive roadmap for userland Doom supportissue_dependencies.dot/.png
- Visual dependency chart of all issuesISSUE_DEPENDENCY_ANALYSIS.md
- Detailed dependency analysis and implementation strategy
We welcome contributions from developers of all skill levels! ๐
- New Contributors: Start with our Contributing Guide for a complete development workflow
- Find Tasks: Check GitHub Issues or browse
tasks.json
for detailed task tracking - High Priority: Issues #89, #96, #108 are ready to implement with no blocking dependencies
- Report Issues: Use our issue templates to report bugs or request features
- Security Issues: Please review our Security Policy for responsible disclosure
- Code Style: Follow the guidelines in
CODING.md
- Community: Read our Code of Conduct
Whether you're interested in kernel development, want to learn about operating systems, or just want to help us reach the goal of running Doom in userland, there's a place for you in the meniOS community!
This project is licensed under the MIT License - see the LICENSE file for details.
Copyright (c) 2020-2025 Plรญnio Balduino
- Intelยฎ 64 and IA-32 Architectures Software Developer's Manual Combined Volumes: 1, 2A, 2B, 2C, 2D, 3A, 3B, 3C, 3D, and 4: https://www.intel.com/content/www/us/en/developer/articles/technical/intel-sdm.html
- PIC: https://pdos.csail.mit.edu/6.828/2014/readings/hardware/8259A.pdf http://www.brokenthorn.com/Resources/OSDevPic.html
- APIC: http://web.archive.org/web/20070112195752/http://developer.intel.com/design/pentium/datashts/24201606.pdf
- ATA: http://learnitonweb.com/2020/05/22/12-developing-an-operating-system-tutorial-episode-6-ata-pio-driver-osdev/ http://www.t13.org/Documents/UploadedDocuments/docs2016/di529r14-ATAATAPI_Command_Set_-_4.pdf p.74
- ASM: https://bitismyth.wordpress.com/assembly-bunker/
- Mem: https://arjunsreedharan.org/post/148675821737/memory-allocators-101-write-a-simple-memory
- AMD: https://developer.amd.com/resources/developer-guides-manuals/ https://www.amd.com/system/files/TechDocs/48751_16h_bkdg.pdf
- Limine Protocol: https://codeberg.org/Limine/limine-protocol/src/branch/trunk/PROTOCOL.md