acompiled

The catalog contains seeded project examples. Your workspace stores your own projects and conversations.

kestrel-os/kestrel

Public
Star8

A small x86-64 kernel. Stage 0 goes from real mode to long mode inside the boot sector.

History
18 lines·462 B·NASM Raw Blame
1; boot.asm — Kestrel stage 0.
2;
3; The BIOS loads this sector at 0x7C00 and jumps to it in 16-bit real mode.
4; For now it only proves that the sector boots: it halts, forever.
5;
6; nasm -f bin boot.asm -o boot.bin
7; qemu-system-x86_64 -drive format=raw,file=boot.bin
8
9 bits 16
10 org 0x7C00
12start:
13 cli
14.halt: hlt
15 jmp .halt
17 times 510 - ($ - $$) db 0
18 dw 0xAA55 ; boot signature