diff --git a/kaleid/kernel/mm/map.c b/kaleid/kernel/mm/map.c index 8738e04..96afb64 100644 --- a/kaleid/kernel/mm/map.c +++ b/kaleid/kernel/mm/map.c @@ -68,9 +68,10 @@ static error_t InitMemoryMap(void) // fill the map while (currentEntry < mapEnd) { + // memory zone address - memoryMap.entry[i].addr = (void*)((ulong)currentEntry->addr_low + - (((ulong)currentEntry->addr_high) << 32 )); + memoryMap.entry[i].addr = (void*)((ullong)currentEntry->addr_low + + (((ullong)currentEntry->addr_high) << 32 )); // memory zone size in bytes memoryMap.entry[i].length = (ulong)currentEntry->len_low + (((ulong)currentEntry->len_high) << 32); @@ -82,6 +83,10 @@ static error_t InitMemoryMap(void) currentEntry = (multiboot_memory_map_t*) ((ulong)currentEntry + currentEntry->size + sizeof(currentEntry->size)); i++; + + //DebugLog("addr high : %x, %x\n", currentEntry->addr_high,(ulong)currentEntry->addr_high); + DebugLog("addr shift %x\n", ((currentEntry->addr_high) << 32)); + } DebugLog("[InitMemoryMap] %d entries detected in the memory map\n",