From b5dcf57c317715a4339e0b4a0bf61ec5e8e94ca0 Mon Sep 17 00:00:00 2001 From: Nathan Ringo Date: Sun, 25 Feb 2024 02:24:26 -0600 Subject: [console] Adds a "strict flush" routine. When this routine is set by the platform-specific code, it is run after every log message. This is a permanently temporary measure to make it easier to debug boot problems with the kernel when bringing it up on a new platform. --- boards/qemu-virt/qemu-virt.ld | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) (limited to 'boards') diff --git a/boards/qemu-virt/qemu-virt.ld b/boards/qemu-virt/qemu-virt.ld index 9673637..1b9ff79 100644 --- a/boards/qemu-virt/qemu-virt.ld +++ b/boards/qemu-virt/qemu-virt.ld @@ -3,27 +3,34 @@ ENTRY(_start) SECTIONS { . = 0x80000000; + + PROVIDE(kernel_start = .); .text : { *(.text.start) *(.text .text.*) - . = ALIGN(0x1000); } - + . = ALIGN(0x1000); .rodata : { - *(.rodata) - . = ALIGN(0x1000); + *(.srodata .srodata.*) + . = ALIGN(16); + *(.rodata .rodata.*) } - + . = ALIGN(0x1000); .data : { - *(.data) + *(.sdata .sdata.*) + . = ALIGN(16); + *(.data .data.*) + . = ALIGN(16); } .bss : { - *(.bss) - . = ALIGN(0x1000); + *(.sbss .sbss.*) + . = ALIGN(16); + *(.bss .bss.*) } - + . = ALIGN(0x1000); .hart0_initial_stack : { . += 0x1000; PROVIDE(hart0_initial_stack_top = .); } + PROVIDE(kernel_end = .); } -- cgit v1.2.3