From ed1d116e62b57b9c5c8746d17ecbf842845d4be2 Mon Sep 17 00:00:00 2001 From: Josef Kellermann Date: Thu, 24 Feb 2011 14:35:42 +0000 Subject: Add compile-time defaults to some K8 CMOS options in case they're absent in CMOS This affects the CMOS options iommu, ECC_memory, max_mem_clock, hw_scrubber, interleave_chip_selects. If they're absent in cmos.layout, a Kconfig value is used if it exists, or a hardcoded default otherwise. [Patrick: I changed the ramstage CMOS handling a bit, and dropped the reliance of hw_scrubber on ECC RAM, as it has nothing to do with it - it's the cache that's being scrubbed here.] Signed-off-by: Josef Kellermann Acked-by: Patrick Georgi git-svn-id: svn://svn.coreboot.org/coreboot/trunk@6380 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1 --- src/cpu/amd/model_fxx/Kconfig | 4 ++++ src/cpu/amd/model_fxx/model_fxx_init.c | 5 ++++- 2 files changed, 8 insertions(+), 1 deletion(-) (limited to 'src/cpu') diff --git a/src/cpu/amd/model_fxx/Kconfig b/src/cpu/amd/model_fxx/Kconfig index 962b399e03..e04605bfbe 100644 --- a/src/cpu/amd/model_fxx/Kconfig +++ b/src/cpu/amd/model_fxx/Kconfig @@ -14,6 +14,10 @@ config SET_FIDVID default n default y if K8_REV_F_SUPPORT +config HW_SCRUBBER + bool + default n + if SET_FIDVID config SET_FIDVID_DEBUG bool diff --git a/src/cpu/amd/model_fxx/model_fxx_init.c b/src/cpu/amd/model_fxx/model_fxx_init.c index a5112b3823..0608d0ae42 100644 --- a/src/cpu/amd/model_fxx/model_fxx_init.c +++ b/src/cpu/amd/model_fxx/model_fxx_init.c @@ -264,7 +264,10 @@ static void init_ecc_memory(unsigned node_id) /* See if we scrubbing should be enabled */ enable_scrubbing = 1; - get_option(&enable_scrubbing, "hw_scrubber"); + if( get_option(&enable_scrubbing, "hw_scrubber") < 0 ) + { + enable_scrubbing = CONFIG_HW_SCRUBBER; + } /* Enable cache scrubbing at the lowest possible rate */ if (enable_scrubbing) { -- cgit v1.2.3