summaryrefslogtreecommitdiff
path: root/src/kernel/mem/paging.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/kernel/mem/paging.cpp')
-rw-r--r--src/kernel/mem/paging.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/kernel/mem/paging.cpp b/src/kernel/mem/paging.cpp
index 8beee16..206cc08 100644
--- a/src/kernel/mem/paging.cpp
+++ b/src/kernel/mem/paging.cpp
@@ -38,8 +38,8 @@ void paging_init(size_t totalRam) {
uint32_t i;
frames.size = totalRam / 0x1000;
- frames.bits = (uint32_t*)ksbrk(INDEX_FROM_BIT(frames.size));
- memset(frames.bits, 0, INDEX_FROM_BIT(frames.size));
+ frames.bits = (uint32_t*)ksbrk(frames.mem_size());
+ memset(frames.bits, 0, frames.mem_size());
kernel_pagedir = (page_directory*)ksbrk(sizeof(page_directory));
kernel_pagedir->mappedSegs = 0;