From 513a1a81f778b9fddbb55a36a38b2dd855215327 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ky=C3=B6sti=20M=C3=A4lkki?= Date: Sun, 3 Jun 2018 12:29:50 +0300 Subject: arch/x86 cbmem: Drop tests for LATE_CBMEM_INIT MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Remove all cases in code where we tested for EARLY_CBMEM_INIT or LATE_CBMEM_INIT being set. This also removes all references to LATE_CBMEM_INIT in comments. Change-Id: I4e47fb5c8a947d268f4840cfb9c0d3596fb9ab39 Signed-off-by: Kyösti Mälkki Reviewed-on: https://review.coreboot.org/c/26827 Reviewed-by: Nico Huber Reviewed-by: Aaron Durbin Tested-by: build bot (Jenkins) --- src/include/cbmem.h | 7 ------- src/include/console/cbmem_console.h | 7 ++----- src/include/timestamp.h | 5 +---- 3 files changed, 3 insertions(+), 16 deletions(-) (limited to 'src/include') diff --git a/src/include/cbmem.h b/src/include/cbmem.h index 562829801e..ad48e357b7 100644 --- a/src/include/cbmem.h +++ b/src/include/cbmem.h @@ -156,15 +156,8 @@ void cbmem_add_records_to_cbtable(struct lb_header *header); * value stored in nvram to enable early recovery on S3 path. */ #if IS_ENABLED(CONFIG_ARCH_X86) -/* Note that with LATE_CBMEM_INIT, restore_top_of_low_cacheable() - * may conditionally return 0 when the sleep type is non S3, - * i.e. cold and warm boots would return NULL also for cbmem_top. */ void backup_top_of_low_cacheable(uintptr_t ramtop); uintptr_t restore_top_of_low_cacheable(void); -uintptr_t restore_cbmem_top(void); - -/* Deprecated, only use with LATE_CBMEM_INIT. */ -void set_late_cbmem_top(uintptr_t ramtop); #endif /* diff --git a/src/include/console/cbmem_console.h b/src/include/console/cbmem_console.h index a8519d28a9..e0e35b1cef 100644 --- a/src/include/console/cbmem_console.h +++ b/src/include/console/cbmem_console.h @@ -22,11 +22,8 @@ void cbmemc_init(void); void cbmemc_tx_byte(unsigned char data); #define __CBMEM_CONSOLE_ENABLE__ (IS_ENABLED(CONFIG_CONSOLE_CBMEM) && \ - (ENV_RAMSTAGE || ENV_VERSTAGE || ENV_POSTCAR || \ - (IS_ENABLED(CONFIG_EARLY_CBMEM_INIT) && \ - (ENV_ROMSTAGE || \ - (ENV_BOOTBLOCK && IS_ENABLED(CONFIG_BOOTBLOCK_CONSOLE))))\ - )) + (ENV_RAMSTAGE || ENV_VERSTAGE || ENV_POSTCAR || ENV_ROMSTAGE || \ + (ENV_BOOTBLOCK && IS_ENABLED(CONFIG_BOOTBLOCK_CONSOLE)))) #if __CBMEM_CONSOLE_ENABLE__ static inline void __cbmemc_init(void) { cbmemc_init(); } diff --git a/src/include/timestamp.h b/src/include/timestamp.h index 7b2b480cf2..2074b71408 100644 --- a/src/include/timestamp.h +++ b/src/include/timestamp.h @@ -19,8 +19,7 @@ #include -#if IS_ENABLED(CONFIG_COLLECT_TIMESTAMPS) && (IS_ENABLED(CONFIG_EARLY_CBMEM_INIT) \ - || !defined(__PRE_RAM__)) +#if IS_ENABLED(CONFIG_COLLECT_TIMESTAMPS) /* * timestamp_init() needs to be called once for each of these cases: * 1. __PRE_RAM__ (bootblock, romstage, verstage, etc) and @@ -59,8 +58,6 @@ uint32_t get_us_since_boot(void); /** * Workaround for guard combination above. - * Looks like CONFIG_EARLY_CBMEM_INIT selects - * timestamp.c to be build. */ #if IS_ENABLED(CONFIG_COLLECT_TIMESTAMPS) /* Implemented by the architecture code */ -- cgit v1.2.3