Kyösti Mälkki (kyosti.malkki@gmail.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/6078
-gerrit
commit 9c72aba558d5af0968042022b94f1eefeaa163a7 Author: Kyösti Mälkki kyosti.malkki@gmail.com Date: Thu Jun 19 20:52:39 2014 +0300
cpu/amd/agesa: Use acpi_is_wakeup()
Change test to return true on S2 wakeup too. In S2 CPU would have been powered down so MTRR recovery is required.
Change-Id: I6ad5fb7e32c59be7d84f28461c238c3975e1e04e Signed-off-by: Kyösti Mälkki kyosti.malkki@gmail.com --- src/cpu/amd/agesa/family14/model_14_init.c | 6 +----- src/cpu/amd/agesa/family15tn/model_15_init.c | 6 +----- src/cpu/amd/agesa/family16kb/model_16_init.c | 6 +----- 3 files changed, 3 insertions(+), 15 deletions(-)
diff --git a/src/cpu/amd/agesa/family14/model_14_init.c b/src/cpu/amd/agesa/family14/model_14_init.c index 1a97f2c..60a88c7 100644 --- a/src/cpu/amd/agesa/family14/model_14_init.c +++ b/src/cpu/amd/agesa/family14/model_14_init.c @@ -32,9 +32,7 @@ #include <cpu/x86/mtrr.h> #include <cpu/amd/amdfam14.h> #include <arch/acpi.h> -#if CONFIG_HAVE_ACPI_RESUME #include <cpu/amd/agesa/s3_resume.h> -#endif
#define MCI_STATUS 0x401
@@ -75,10 +73,8 @@ static void model_14_init(device_t dev) msr.lo |= SYSCFG_MSR_MtrrFixDramEn; wrmsr(SYSCFG_MSR, msr);
-#if CONFIG_HAVE_ACPI_RESUME - if (acpi_slp_type == 3) + if (acpi_is_wakeup()) restore_mtrr(); -#endif
x86_mtrr_check(); x86_enable_cache(); diff --git a/src/cpu/amd/agesa/family15tn/model_15_init.c b/src/cpu/amd/agesa/family15tn/model_15_init.c index 467a301..64c78af 100644 --- a/src/cpu/amd/agesa/family15tn/model_15_init.c +++ b/src/cpu/amd/agesa/family15tn/model_15_init.c @@ -33,9 +33,7 @@ #include <cpu/x86/mtrr.h> #include <cpu/amd/amdfam15.h> #include <arch/acpi.h> -#if CONFIG_HAVE_ACPI_RESUME #include <cpu/amd/agesa/s3_resume.h> -#endif
static void model_15_init(device_t dev) { @@ -73,10 +71,8 @@ static void model_15_init(device_t dev) msr.lo |= SYSCFG_MSR_MtrrFixDramEn; wrmsr(SYSCFG_MSR, msr);
-#if CONFIG_HAVE_ACPI_RESUME - if (acpi_slp_type == 3) + if (acpi_is_wakeup()) restore_mtrr(); -#endif
x86_mtrr_check(); x86_enable_cache(); diff --git a/src/cpu/amd/agesa/family16kb/model_16_init.c b/src/cpu/amd/agesa/family16kb/model_16_init.c index 734d9ef..ef31f96 100644 --- a/src/cpu/amd/agesa/family16kb/model_16_init.c +++ b/src/cpu/amd/agesa/family16kb/model_16_init.c @@ -32,9 +32,7 @@ #include <cpu/x86/mtrr.h> #include <cpu/amd/amdfam16.h> #include <arch/acpi.h> -#if CONFIG_HAVE_ACPI_RESUME #include <cpu/amd/agesa/s3_resume.h> -#endif
static void model_16_init(device_t dev) { @@ -71,10 +69,8 @@ static void model_16_init(device_t dev) msr.lo |= SYSCFG_MSR_MtrrFixDramEn; wrmsr(SYSCFG_MSR, msr);
-#if CONFIG_HAVE_ACPI_RESUME - if (acpi_slp_type == 3) + if (acpi_is_wakeup()) restore_mtrr(); -#endif
x86_mtrr_check(); x86_enable_cache();