diff options
author | Duncan Laurie <dlaurie@chromium.org> | 2012-01-09 22:41:35 -0800 |
---|---|---|
committer | Stefan Reinauer <reinauer@chromium.org> | 2012-01-10 10:17:15 -0800 |
commit | 2a32ec44c4aba4660ba3a46f8bf946b421545cf4 (patch) | |
tree | 9ab459cc32a953ca667f41de57d55d91bcdce8ee /arch | |
parent | d9def8a7ff9409b92b837000b2f439af785d1a31 (diff) |
CHROMIUM: x86: Ignore memory >4GB when parsing Coreboot tables
U-boot is unable to actually use that memory and it can
cause problems with relocation if it tries to.
BUG=chrome-os-partner:6730
TEST=successfully boot on stumpy with a memory map
that ends up having 6MB remapped above 4GB.
Change-Id: I9ecde227bc0337145a7c0a6a929cfe0636fc2178
Signed-off-by: Duncan Laurie <dlaurie@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/13923
Reviewed-by: Stefan Reinauer <reinauer@chromium.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/cpu/coreboot/sdram.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/x86/cpu/coreboot/sdram.c b/arch/x86/cpu/coreboot/sdram.c index dd73e0fa1b3..fb6515f8841 100644 --- a/arch/x86/cpu/coreboot/sdram.c +++ b/arch/x86/cpu/coreboot/sdram.c @@ -59,6 +59,10 @@ int dram_init_f(void) { struct memrange *memrange = &lib_sysinfo.memrange[i]; unsigned long long end = memrange->base + memrange->size; + /* Ignore memory over 4GB, we can't use it. */ + if (memrange->base > 0xffffffff) + continue; + if (memrange->type == CB_MEM_RAM && end > ram_size) ram_size = end; } |