From bfec696da052c8c9320773ca69927422efebe8c7 Mon Sep 17 00:00:00 2001 From: Alexis211 Date: Tue, 22 Dec 2009 16:48:52 +0100 Subject: [noncompiling commit] Started working on a segmented memory model --- Source/Kernel/MemoryManager/Mem.ns.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Source/Kernel/MemoryManager/Mem.ns.cpp') diff --git a/Source/Kernel/MemoryManager/Mem.ns.cpp b/Source/Kernel/MemoryManager/Mem.ns.cpp index a0809b0..712c0f3 100644 --- a/Source/Kernel/MemoryManager/Mem.ns.cpp +++ b/Source/Kernel/MemoryManager/Mem.ns.cpp @@ -20,7 +20,7 @@ void *kallocInternal(size_t sz, bool align) { u32int temp = placementAddress; placementAddress += sz; for (u32int i = temp; i < placementAddress; i += 0x1000) { - if (pagingEnabled) kernelPageDirectory->allocFrame(i, false, false); + if (pagingEnabled) PhysMem::keSeg.allocFrame(i); } return (void*)temp; } @@ -34,7 +34,7 @@ void createHeap() { u32int heapSize = HEAP_MIN_SIZE + heapIndexSize; //Calculate heap size for (u32int i = (placementAddress & 0xFFFFF000); i < heapStart; i += 0x1000) { - kernelPageDirectory->allocFrame(i, false, false); + PhysMem::keSeg.allocFrame(i); } kheap.create(heapStart, heapSize, heapIndexSize, kernelPageDirectory, false, false); -- cgit v1.2.3