diff options
| author | Matteo Gmür <matteo.gmuer1@ost.ch> | 2024-11-24 13:55:00 +0000 |
|---|---|---|
| committer | Matteo Gmür <matteo.gmuer1@ost.ch> | 2024-11-24 13:55:00 +0000 |
| commit | 82cfe7fe12626a3bdf1bdf9efcbc7911051ebddf (patch) | |
| tree | b8cacfba703bdc8786493b04d9096e8097448d39 /arch | |
| parent | c291e1ed629489c418049f6c4116433636717636 (diff) | |
| download | teachos-82cfe7fe12626a3bdf1bdf9efcbc7911051ebddf.tar.xz teachos-82cfe7fe12626a3bdf1bdf9efcbc7911051ebddf.zip | |
Read and write in allocated memory area
Diffstat (limited to 'arch')
| -rw-r--r-- | arch/x86_64/src/kernel/main.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/x86_64/src/kernel/main.cpp b/arch/x86_64/src/kernel/main.cpp index ce13723..f4eb033 100644 --- a/arch/x86_64/src/kernel/main.cpp +++ b/arch/x86_64/src/kernel/main.cpp @@ -19,10 +19,10 @@ namespace teachos::arch::kernel memory::heap::bump_allocator heap_allocator{memory::heap::HEAP_START, memory::heap::HEAP_START + memory::heap::HEAP_SIZE}; auto test = heap_allocator.allocate(1024); - auto test2 = new (test) memory::multiboot::memory_information{}; - - if (test || test2) + test2->kernel_end = 5000; + auto test3 = test2->kernel_end; + if (test || test2 || test3) { video::vga::text::write("Kernel remapping successfull", video::vga::text::common_attributes::green_on_black); } |
