From 59d0e040c89b5eea5f2febfa73de57d45a9ae535 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Sat, 5 Sep 2015 18:40:31 -0500 Subject: northbridge/amd/amdmct/mct_ddr3: Add initial Suspend to RAM (S3) support Change-Id: Ic97567851fa40295bc21cefd7537407b99d71709 Signed-off-by: Timothy Pearson Reviewed-on: http://review.coreboot.org/11952 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich --- src/northbridge/amd/amdfam10/Makefile.inc | 2 ++ src/northbridge/amd/amdfam10/northbridge.c | 8 ++++++++ 2 files changed, 10 insertions(+) (limited to 'src/northbridge/amd/amdfam10') diff --git a/src/northbridge/amd/amdfam10/Makefile.inc b/src/northbridge/amd/amdfam10/Makefile.inc index e4dd9e39f6..f083f31c87 100644 --- a/src/northbridge/amd/amdfam10/Makefile.inc +++ b/src/northbridge/amd/amdfam10/Makefile.inc @@ -28,4 +28,6 @@ s3nv-file := $(obj)/coreboot_s3nv.rom s3nv-align := $(CONFIG_S3_DATA_SIZE) s3nv-type := raw +ramstage-$(CONFIG_DIMM_DDR3) += ../amdmct/mct_ddr3/s3utils.c + endif diff --git a/src/northbridge/amd/amdfam10/northbridge.c b/src/northbridge/amd/amdfam10/northbridge.c index 74cecc894a..d4fe986298 100644 --- a/src/northbridge/amd/amdfam10/northbridge.c +++ b/src/northbridge/amd/amdfam10/northbridge.c @@ -54,6 +54,10 @@ #include #endif +#if IS_ENABLED(CONFIG_DIMM_DDR3) +#include "../amdmct/mct_ddr3/s3utils.h" +#endif + struct amdfam10_sysconf_t sysconf; #define FX_DEVS NODE_NUMS @@ -1413,6 +1417,10 @@ static void root_complex_enable_dev(struct device *dev) /* Do not delay UMA setup, as a device on the PCI bus may evaluate the global uma_memory variables already in its enable function. */ if (!done) { +#if IS_ENABLED(CONFIG_HAVE_ACPI_RESUME) && IS_ENABLED(CONFIG_DIMM_DDR3) + save_mct_information_to_nvram(); +#endif + setup_bsp_ramtop(); setup_uma_memory(); done = 1; -- cgit v1.2.3