diff --git a/core/mem.c b/core/mem.c index 3acffa8b..e39156b6 100644 --- a/core/mem.c +++ b/core/mem.c @@ -159,7 +159,7 @@ free_frame( void paging_install(uint32_t memsize) { - nframes = 0x1000; //memsize / 4; + nframes = memsize / 4; frames = (uint32_t *)kmalloc(INDEX_FROM_BIT(nframes)); memset(frames, 0, INDEX_FROM_BIT(nframes)); kernel_directory = (page_directory_t *)kvmalloc(sizeof(page_directory_t)); diff --git a/main.c b/main.c index 5bf1f4a2..50dee575 100644 --- a/main.c +++ b/main.c @@ -130,7 +130,7 @@ main(struct multiboot *mboot_ptr) { isrs_install(); irq_install(); init_video(); - paging_install(mboot_ptr->mem_upper); + paging_install(mboot_ptr->mem_upper + 1024); timer_install(); keyboard_install(); /* Yes, yes, these are #define'd strings, consider this a nice test of kprintf */