aboutsummaryrefslogtreecommitdiff
path: root/arch/x86_64/src/kernel/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86_64/src/kernel/main.cpp')
-rw-r--r--arch/x86_64/src/kernel/main.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/arch/x86_64/src/kernel/main.cpp b/arch/x86_64/src/kernel/main.cpp
index 13526f4..023327e 100644
--- a/arch/x86_64/src/kernel/main.cpp
+++ b/arch/x86_64/src/kernel/main.cpp
@@ -20,9 +20,10 @@ namespace teachos::arch::kernel
memory::heap::HEAP_START + memory::heap::HEAP_SIZE};
auto test = heap_allocator.allocate(1024);
auto test2 = new (test) memory::multiboot::memory_information{};
- test2->kernel_end = 5000;
- auto test3 = test2->kernel_end;
- if (test || test2 || test3)
+ auto test3 = *test2;
+ test3.kernel_end = 5000;
+ auto test4 = test3.kernel_end;
+ if (test || test2 || test3.kernel_end || test4)
{
video::vga::text::write("Kernel remapping successfull", video::vga::text::common_attributes::green_on_black);
}
@@ -31,7 +32,5 @@ namespace teachos::arch::kernel
// allocator.allocate_frame still works?
// TODO: Fix unmapping old level 4 page table and turn it into guard page, use Stack Probes for stack allocation if
// possible.
-
- // TODO: Align up and down for the bump allocator. https://os.phil-opp.com/kernel-heap/#a-bump-allocator
}
} // namespace teachos::arch::kernel