1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-28 04:27:45 +00:00

Kernel/aarch64: Only identity map kernel image, instead of all of RAM

For the initial page tables we only need to identity map the kernel
image, the rest of the memory will be managed by the MemoryManager. The
linker script is updated to get the kernel image start and end
addresses.
This commit is contained in:
Timon Kruiper 2022-09-21 16:16:39 +02:00 committed by Andreas Kling
parent cdf59c86ac
commit a62732ee2f
3 changed files with 17 additions and 3 deletions

View file

@ -13,6 +13,8 @@ SECTIONS
{
. = 0x00080000;
start_of_kernel_image = .;
.text ALIGN(4K) : AT (ADDR(.text))
{
*(.text.first)
@ -62,8 +64,6 @@ SECTIONS
/* FIXME: Placeholder to satisfy linker */
start_of_kernel_text = .;
end_of_kernel_text = .;
start_of_kernel_image = .;
end_of_kernel_image = .;
start_of_unmap_after_init = .;
end_of_unmap_after_init = .;
start_of_ro_after_init = .;
@ -76,6 +76,8 @@ SECTIONS
. += 8M;
page_tables_phys_end = .;
end_of_kernel_image = .;
}
size_of_bss_divided_by_8 = (end_of_bss - start_of_bss + 7) / 8;