summaryrefslogtreecommitdiffstats
path: root/arch/x86
diff options
context:
space:
mode:
authorBin Meng <bmeng.cn@gmail.com>2018-06-22 01:38:30 -0700
committerBin Meng <bmeng.cn@gmail.com>2018-06-24 08:56:25 +0800
commit598374729e6b3f3070e06bdf2990dd8d10cddbda (patch)
tree70a507e2a9cc789953d378a8c36dad82515c7f31 /arch/x86
parent1ffa447b8c8fd84937f41f5084ac802136773357 (diff)
downloadu-boot-598374729e6b3f3070e06bdf2990dd8d10cddbda.tar.gz
u-boot-598374729e6b3f3070e06bdf2990dd8d10cddbda.tar.xz
u-boot-598374729e6b3f3070e06bdf2990dd8d10cddbda.zip
x86: efi: payload: Count in conventional memory above 4GB in DRAM bank
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>
Diffstat (limited to 'arch/x86')
-rw-r--r--arch/x86/cpu/efi/payload.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/x86/cpu/efi/payload.c b/arch/x86/cpu/efi/payload.c
index e3f0f825f3..4649bfe86e 100644
--- a/arch/x86/cpu/efi/payload.c
+++ b/arch/x86/cpu/efi/payload.c
@@ -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;