Luna/kernel/src/main.asm

18 lines
348 B
NASM
Raw Normal View History

global _main
extern _start
_main:
xor rbp, rbp
call _start
global _userspace
_userspace:
mov rdi, 4000 ; 4000 ms / 4 seconds
int 33h ; Sleep
mov rdi, .message
int 32h ; Print string
mov rdi, 2000 ; 2000 ms / 2 seconds
int 33h ; Sleep
int 31h ; Exit current task
.message:
db "hello from userspace!", 0xA, 0