Add a bootstrap physical memory manager.
This will allow the real physical memory manager to use allocations.
This commit is contained in:
parent
747c2a4e17
commit
2d719d0443
5 changed files with 105 additions and 6 deletions
|
|
@ -1,21 +1,22 @@
|
|||
#include <stdint.h>
|
||||
|
||||
#include "boot/boot_info.h"
|
||||
#include "boot/limine.h"
|
||||
#include "common/gdt.h"
|
||||
#include "debug/debug.h"
|
||||
#include "interrupt/interrupt.h"
|
||||
#include "memory/kernel_heap.h"
|
||||
#include "memory/paging_util.h"
|
||||
#include "memory/physical_memory.h"
|
||||
|
||||
extern "C" void zion() {
|
||||
InitGdt();
|
||||
InitIdt();
|
||||
InitPaging();
|
||||
|
||||
phys_mem::InitBootstrapPageAllocation();
|
||||
KernelHeap heap(0xFFFFFFFF'40000000, 0xFFFFFFFF'80000000);
|
||||
heap.Allocate(1);
|
||||
|
||||
dbgln("Sleeping!");
|
||||
while (1)
|
||||
;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue