This is a small map of how the current system boots and where the major pieces live.
- GRUB loads the kernel through Multiboot2.
- The 32-bit bootstrap code:
- verifies Multiboot handoff
- checks CPU support
- sets up the early page tables
- enables long mode
- Control transfers into 64-bit assembly startup.
- 64-bit startup calls
kernel_main(). - The C kernel initializes:
- console / boot output
- IDT
- PIC remap
- PIT timer
- keyboard IRQ support
- shell
Files:
arch/x86_64/impl/boot/header.asmarch/x86_64/impl/boot/main.asmarch/x86_64/impl/boot/main64.asm
Responsibilities:
- Multiboot2 header
- early CPU checks
- initial paging setup
- transition to long mode
- transfer into C
File:
arch/x86_64/impl/kernel/main.c
Responsibilities:
- high-level bring-up order
- boot log flow
- shell handoff
Files:
arch/x86_64/impl/print.carch/x86_64/intf/print.h
Responsibilities:
- writing to VGA text memory
- newline / scrolling behavior
- cursor updates
- integer / hex helpers
- optional serial mirroring during boot
Files:
arch/x86_64/impl/idt.carch/x86_64/impl/interrupts.asmarch/x86_64/intf/idt.harch/x86_64/intf/interrupts.h
Responsibilities:
- IDT setup
- exception entry stubs
- IRQ entry stubs
- fault reporting
Files:
arch/x86_64/impl/pic.carch/x86_64/impl/pit.carch/x86_64/intf/pic.harch/x86_64/intf/pit.h
Responsibilities:
- PIC remap
- IRQ masking / unmasking
- PIT initialization
- tick counting
Files:
arch/x86_64/impl/keyboard.carch/x86_64/intf/keyboard.h
Responsibilities:
- PS/2 scancode handling
- modifier tracking
- shell navigation keys
- Ctrl-C handling
Files:
arch/x86_64/impl/shell.carch/x86_64/intf/shell.h
Responsibilities:
- prompt and command loop
- line editing
- history recall
- built-in commands
Files:
arch/x86_64/impl/serial.carch/x86_64/intf/serial.h
Responsibilities:
- COM1 initialization
- serial character / string output
- boot diagnostics outside VGA
Files:
arch/x86_64/impl/io.carch/x86_64/intf/io.h
Responsibilities:
inboutb- tiny I/O wait helper
arch/x86_64/impl/
boot/ bootstrap asm and long-mode entry
kernel/ high-level kernel startup
*.c subsystem implementations
*.asm interrupt / low-level assembly glue
arch/x86_64/intf/
*.h subsystem interfaces
targets/x86_64/
linker.ld linker script
iso/ GRUB boot tree used to build kernel.iso
buildenv/
Dockerfile reproducible build environment
pics/
screenshots / images
tiny64os is best thought of as:
- a bootable x86_64 kernel
- a text console environment
- a hardware-interrupt example that is already usable
- a compact base for learning how these pieces fit together
The goal here is not to become huge quickly. The goal is to stay readable while still showing a real interrupt-driven system with a basic shell.