X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=blobdiff_plain;f=test%2Fgeekos_test_vm%2Fsrc%2Fgeekos%2Fmem.c;h=6ab2051ff3b9937a307203da7e41bbbf88ccd497;hb=cd89b672b4f7e1b64c86ff0234a9935946533590;hp=2f44520ab8bc9384c775c0734180f9fd78718762;hpb=f40945e5a406b48b7b5ee678a3d8d8f0b56f7d74;p=palacios-OLD.git diff --git a/test/geekos_test_vm/src/geekos/mem.c b/test/geekos_test_vm/src/geekos/mem.c index 2f44520..6ab2051 100644 --- a/test/geekos_test_vm/src/geekos/mem.c +++ b/test/geekos_test_vm/src/geekos/mem.c @@ -109,7 +109,11 @@ void Init_Mem(struct Boot_Info* bootInfo) ulong_t pageListAddr; ulong_t kernEnd; + + memset(&s_freeList, 0, sizeof(struct Page_List)); + KASSERT(bootInfo->memSizeKB > 0); + Print("Booting with %d KB memory\n", bootInfo->memSizeKB); /* * Before we do anything, switch from setup.asm's temporary GDT @@ -180,10 +184,12 @@ void Init_Mem(struct Boot_Info* bootInfo) /* Initialize the kernel heap */ // Init_Heap(HIGHMEM_START, KERNEL_HEAP_SIZE); + + Print("Initing heap\n"); Init_Heap(kernEnd, KERNEL_HEAP_SIZE); Print("%uKB memory detected, %u pages in freelist, %d bytes in kernel heap\n", - bootInfo->memSizeKB, g_freePageCount, KERNEL_HEAP_SIZE); + bootInfo->memSizeKB, g_freePageCount, KERNEL_HEAP_SIZE); } /*