basic os stuff

This commit is contained in:
CScatgirl
2026-03-02 17:37:33 -05:00
commit e6231d46f2
7 changed files with 342 additions and 0 deletions

28
entry.asm Normal file
View File

@@ -0,0 +1,28 @@
[BITS 16]
extern _kmain
global kernel_entry
global _small_code_ ; Watcom small model expects this
segment _TEXT class=CODE
_small_code_: ; Must be at start of CODE segment
kernel_entry:
cli
mov ax, 0x1000
mov ds, ax
mov es, ax
mov ss, ax
mov sp, 0x7000 ; Just use a fixed address for stack
xor bp, bp
sti
call _kmain
.halt:
cli
hlt
jmp .halt
segment _BSS class=BSS
resb 4096