From 66268f7d7f6bd29191d517574346730aeef597f5 Mon Sep 17 00:00:00 2001 From: mintsuki Date: Thu, 15 Jun 2023 13:06:52 +0200 Subject: [PATCH] pmm: Use fixed value of 1024 for recl entries count --- common/mm/pmm.s2.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/common/mm/pmm.s2.c b/common/mm/pmm.s2.c index fc7185e0..ce21a55a 100644 --- a/common/mm/pmm.s2.c +++ b/common/mm/pmm.s2.c @@ -430,14 +430,7 @@ void init_memmap(void) { sanitise_entries(memmap, &memmap_entries, false); - size_t recl_count = 0; - for (size_t i = 0; i < memmap_entries; i++) { - if (memmap[i].type == MEMMAP_EFI_RECLAIMABLE) { - recl_count++; - } - } - - recl = ext_mem_alloc(recl_count * sizeof(struct memmap_entry)); + recl = ext_mem_alloc(1024 * sizeof(struct memmap_entry)); return;