1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-14 11:54:57 +00:00

Kernel: Use the pre-image kernel memory range introduced by KASLR

This ensures we don't just waste the memory range between the default
base load address and the actual load address that was shifted by the
KASLR offset.
This commit is contained in:
Idan Horowitz 2022-03-22 13:40:21 +02:00 committed by Andreas Kling
parent d850e483f7
commit e18632660f
5 changed files with 11 additions and 3 deletions

View file

@ -184,6 +184,7 @@ extern "C" [[noreturn]] void init()
info.end_of_prekernel_image = (PhysicalPtr)end_of_prekernel_image;
info.physical_to_virtual_offset = kernel_load_base - kernel_physical_base;
info.kernel_mapping_base = kernel_mapping_base;
info.default_kernel_load_base = default_kernel_load_base;
info.kernel_load_base = kernel_load_base;
#if ARCH(X86_64)
info.gdt64ptr = (PhysicalPtr)gdt64ptr;