Print the device tree node names

This commit is contained in:
2025-07-05 00:42:04 +02:00
parent 6c6a65c169
commit 98a96fba86
4 changed files with 280 additions and 10 deletions

View File

@ -30,7 +30,10 @@ kernel_main:
la t0, kernel_entry
csrw stvec, t0
unimp
# unimp
mv a0, a1
call device_tree
.Lkernel_main:
j .Lkernel_main
@ -130,8 +133,8 @@ handle_trap:
csrr t1, stval
csrr t2, sepc
li a0, PANIC_MESSAGE_SIZE
la a1, panic_message
li a1, PANIC_MESSAGE_SIZE
la a0, panic_message
call write_s
li a0, ' '
@ -181,7 +184,12 @@ panic:
.section .text.boot
boot:
la a0, __stack_top
mv sp, a0 # Set the stack pointer
la t0, __stack_top
mv sp, t0 # Set the stack pointer
lw t0, (__free_ram)
la t1, next_paddr
sw t0, (t1)
call bzero
j kernel_main