paging at boot works now!!!!
This commit is contained in:
39
linker.ld
39
linker.ld
@@ -1,30 +1,25 @@
|
||||
ENTRY(_start)
|
||||
|
||||
KERNEL_VIRT_BASE = 0xC0000000;
|
||||
KERNEL_PHYS_BASE = 0x00100000;
|
||||
|
||||
SECTIONS {
|
||||
. = ALIGN(8);
|
||||
.boot : {
|
||||
KEEP(*(.multiboot))
|
||||
. = KERNEL_VIRT_BASE;
|
||||
|
||||
.text : AT(KERNEL_PHYS_BASE) {
|
||||
*(.text)
|
||||
}
|
||||
. = 1M; /* Load kernel at 1MB */
|
||||
|
||||
.text BLOCK(4K) : ALIGN(4K)
|
||||
{
|
||||
*(.text)
|
||||
}
|
||||
.rodata : AT(KERNEL_PHYS_BASE + (ADDR(.rodata) - KERNEL_VIRT_BASE)) {
|
||||
*(.rodata)
|
||||
}
|
||||
|
||||
.rodata BLOCK(4K) : ALIGN(4K)
|
||||
{
|
||||
*(.rodata)
|
||||
}
|
||||
.data : AT(KERNEL_PHYS_BASE + (ADDR(.data) - KERNEL_VIRT_BASE)) {
|
||||
*(.data)
|
||||
}
|
||||
|
||||
.data BLOCK(4K) : ALIGN(4K)
|
||||
{
|
||||
*(.data)
|
||||
}
|
||||
|
||||
.bss BLOCK(4K) : ALIGN(4K)
|
||||
{
|
||||
*(COMMON)
|
||||
*(.bss)
|
||||
}
|
||||
.bss : AT(KERNEL_PHYS_BASE + (ADDR(.bss) - KERNEL_VIRT_BASE)) {
|
||||
*(COMMON)
|
||||
*(.bss)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user