switch-coreboot/src
Julius Werner 3c814b2e2b cbmem: Always maintain backing store struct in a global on non-x86
The current CBMEM code contains an optimization that maintains the
structure with information about the CBMEM backing store in a global
variable, so that we don't have to recover it from cbmem_top() again
every single time we access CBMEM. However, due to the problems with
using globals in x86 romstage, this optimization has only been enabled
in ramstage.

However, all non-x86 platforms are SRAM-based (at least for now) and
can use globals perfectly fine in earlier stages. Therefore, this patch
extends the optimization on those platforms to all stages. This also
allows us to remove the requirement that cbmem_top() needs to return
NULL before its backing store has been initialized from those boards,
since the CBMEM code can now keep track of whether it has been
initialized by itself.

Change-Id: Ia6c1db00ae01dee485d5e96e4315cb399dc63696
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://review.coreboot.org/16273
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
2016-08-27 01:16:34 +02:00
..
acpi src/acpi: Capitalize ACPI and SATA 2016-07-31 19:25:40 +02:00
arch arch/riscv: Add functions to read/write memory on behalf of supervisor/user mode 2016-08-23 23:48:54 +02:00
commonlib cbfs: Add "struct" file type and associated helpers 2016-08-27 01:16:22 +02:00
console console: Add write line routine 2016-08-10 22:30:19 +02:00
cpu src/cpu: Capitalize CPU, APIC and IOAPIC typo fix 2016-08-23 15:43:58 +02:00
device src/device: Capitalize CPU, RAM and ROM 2016-07-31 18:33:30 +02:00
drivers vboot: consolidate google_chromeec_early_init() calls 2016-08-25 22:50:17 +02:00
ec google/chromeec: Ensure data is ready before reading it 2016-08-20 10:48:37 +02:00
include cbmem: Always maintain backing store struct in a global on non-x86 2016-08-27 01:16:34 +02:00
lib cbmem: Always maintain backing store struct in a global on non-x86 2016-08-27 01:16:34 +02:00
mainboard lenovo/x200,t400: enable C4 cpu low power state 2016-08-27 00:15:41 +02:00
northbridge src/northbridge: Remove unnecessary whitespace before "\n" and "\t" 2016-08-23 15:43:27 +02:00
soc soc/intel/apollolake: Enable ELOG 2016-08-25 23:51:27 +02:00
southbridge sb/amd/sb700: Add option to increase SPI speed to 33MHz 2016-08-26 18:22:33 +02:00
superio superio/*: Relocate Kconfig to chip folder. 2016-08-09 10:38:30 +02:00
vboot vboot: consolidate google_chromeec_early_init() calls 2016-08-25 22:50:17 +02:00
vendorcode drivers/elog: use region_device for NV storage 2016-08-19 18:18:08 +02:00
Kconfig arch/riscv: Print the page table structure after construction 2016-08-23 16:04:55 +02:00