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=c71fc30eb921a0d155d578d609cabdeea9f99d40;hp=2f44520ab8bc9384c775c0734180f9fd78718762;hpb=a70930549d1b741704dd7af4e6bb0e89f6f8a519;p=palacios.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); } /*