SquidgeOS/src/boot/entry.S

20 lines
448 B
ArmAsm
Raw Normal View History

.section .text.boot
2026-02-08 21:23:47 +00:00
.global _start
_start:
# 1. Set up the stack pointer using the symbol from our linker script
la sp, stack_top
# 2. Set up the trap handler (pointing to the one in traps.S)
la t0, trap_entry
csrw mtvec, t0
# 3. Enable FPU (Floating Point)
li t0, 0x00006000
csrs mstatus, t0
# 4. Jump to C
call kmain
2026-02-08 21:23:47 +00:00
loop:
wfi
j loop