From 58decc540dd40c180542d214f74773c7c17b4f28 Mon Sep 17 00:00:00 2001 From: Patrick Georgi Date: Thu, 23 Apr 2015 14:40:22 +0200 Subject: memlayout: Make sure preram_cbmem_console symbols exist This enables its _size variable (a macro) to work even when the console has no location assigned to it in the chip/board's memlayout.ld. Since _size == 0, the code will do the right thing. Change-Id: I6b42ed0c5c3aaa613603680728b61cbdb24c4b61 Signed-off-by: Patrick Georgi Reviewed-on: http://review.coreboot.org/9973 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin --- src/lib/bootblock.ld | 2 ++ src/lib/romstage.ld | 2 ++ 2 files changed, 4 insertions(+) (limited to 'src') diff --git a/src/lib/bootblock.ld b/src/lib/bootblock.ld index 9bd8a86aea..8c93342532 100644 --- a/src/lib/bootblock.ld +++ b/src/lib/bootblock.ld @@ -35,6 +35,8 @@ *(.bss.*); *(.sbss); *(.sbss.*); + _preram_cbmem_console = DEFINED(_preram_cbmem_console) ? _preram_cbmem_console : 0; + _epreram_cbmem_console = DEFINED(_epreram_cbmem_console) ? _epreram_cbmem_console : 0; _ebootblock = .; _eprogram = .; } : to_load = 0xff diff --git a/src/lib/romstage.ld b/src/lib/romstage.ld index c3a2643787..1e80962ab5 100644 --- a/src/lib/romstage.ld +++ b/src/lib/romstage.ld @@ -33,6 +33,8 @@ *(.rodata.*); *(.data); *(.data.*); + _preram_cbmem_console = DEFINED(_preram_cbmem_console) ? _preram_cbmem_console : 0; + _epreram_cbmem_console = DEFINED(_epreram_cbmem_console) ? _epreram_cbmem_console : 0; . = ALIGN(8); } -- cgit v1.2.3