]> git.sur5r.net Git - u-boot/commitdiff
x86: efi: payload: Count in conventional memory above 4GB in DRAM bank
authorBin Meng <bmeng.cn@gmail.com>
Fri, 22 Jun 2018 08:38:30 +0000 (01:38 -0700)
committerBin Meng <bmeng.cn@gmail.com>
Sun, 24 Jun 2018 00:56:25 +0000 (08:56 +0800)
At present in dram_init_banksize() it ignores conventional memory
above 4GB. This leads to wrong DRAM size is printed during boot.
Remove such limitation.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
arch/x86/cpu/efi/payload.c

index e3f0f825f30a67996359b850593f8f0d6fac7dec..4649bfe86eb3baf45135552bea24977e02eb3695 100644 (file)
@@ -109,11 +109,10 @@ int dram_init_banksize(void)
             desc < end && num_banks < CONFIG_NR_DRAM_BANKS;
             desc = efi_get_next_mem_desc(map, desc)) {
                /*
-                * We only use conventional memory below 4GB, and ignore
+                * We only use conventional memory and ignore
                 * anything less than 1MB.
                 */
                if (desc->type != EFI_CONVENTIONAL_MEMORY ||
-                   desc->physical_start >= 1ULL << 32 ||
                    (desc->num_pages << EFI_PAGE_SHIFT) < 1 << 20)
                        continue;
                gd->bd->bi_dram[num_banks].start = desc->physical_start;