libkernaux/examples/bootloader-multiboot2-limine/start.S

31 lines
463 B
ArmAsm
Raw Normal View History

2022-01-09 03:06:03 +00:00
.section .bss
.global _kernel_stack_start
.global _kernel_stack_end
.align 16
_kernel_stack_start:
.skip 16384 # 16 KiB
_kernel_stack_end:
.section .text
.global _start
2022-01-12 09:40:35 +00:00
.type _start, @function
.type main, @function
.type poweroff, @function
2022-01-09 03:06:03 +00:00
_start:
mov $_kernel_stack_end, %esp // Initialize stack
push %ebx // Multiboot information pointer
push %eax // Multiboot magic number
call main
2022-01-12 09:40:35 +00:00
call poweroff
2022-01-09 03:06:03 +00:00
.size _start, . - _start