From 10796d8c1e446d677c563280f9d7ca1905218041 Mon Sep 17 00:00:00 2001 From: Felix Held Date: Mon, 25 Oct 2021 17:52:49 +0200 Subject: src/cpu: drop CPU_X86_CACHE_HELPER and x86_enable_cache wrapper function Selecting CPU_X86_CACHE_HELPER only added the x86_enable_cache wrapper function around enable_cache which additionally wrote a POST code to port 0x80 and printed a message to the console. This function was only called during multi-processor initialization in ramstage via the init function pointer in the CPU's device operations struct and was run on all cores, so the message on the console was printed once per CPU core. This patch replaces all x86_enable_cache calls by calls to enable_cache and removes the wrapper function and the Kconfig symbol CPU_X86_CACHE_HELPER which was used to only add this when the corresponding CPUs used the x86_enable_cache wrapper function. Signed-off-by: Felix Held Suggested-by: Angel Pons Change-Id: I5866b6bf014821ff9e3a48052a5eaf69319b003a Reviewed-on: https://review.coreboot.org/c/coreboot/+/58579 Reviewed-by: Arthur Heymans Reviewed-by: Angel Pons Tested-by: build bot (Jenkins) --- src/cpu/intel/model_6ex/Kconfig | 1 - src/cpu/intel/model_6ex/model_6ex_init.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) (limited to 'src/cpu/intel/model_6ex') diff --git a/src/cpu/intel/model_6ex/Kconfig b/src/cpu/intel/model_6ex/Kconfig index 37bfa14ad1..c7d54c5f8c 100644 --- a/src/cpu/intel/model_6ex/Kconfig +++ b/src/cpu/intel/model_6ex/Kconfig @@ -9,4 +9,3 @@ config CPU_INTEL_MODEL_6EX select SUPPORT_CPU_UCODE_IN_CBFS select CPU_INTEL_COMMON select CPU_INTEL_COMMON_TIMEBASE - select CPU_X86_CACHE_HELPER diff --git a/src/cpu/intel/model_6ex/model_6ex_init.c b/src/cpu/intel/model_6ex/model_6ex_init.c index 16c6866f45..34646ad5e9 100644 --- a/src/cpu/intel/model_6ex/model_6ex_init.c +++ b/src/cpu/intel/model_6ex/model_6ex_init.c @@ -97,7 +97,7 @@ static void model_6ex_init(struct device *cpu) char processor_name[49]; /* Turn on caching if we haven't already */ - x86_enable_cache(); + enable_cache(); /* Print processor name */ fill_processor_name(processor_name); -- cgit v1.2.3