[coreboot-gerrit] New patch to review for coreboot: a3a3d58 AGESA: Move config parameters for non-volatile S3 data

Kyösti Mälkki (kyosti.malkki@gmail.com) gerrit at coreboot.org
Fri Jun 20 17:20:32 CEST 2014


Kyösti Mälkki (kyosti.malkki at gmail.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/6081

-gerrit

commit a3a3d5834553e9c5ca76ac7571ac98aef105b2c2
Author: Kyösti Mälkki <kyosti.malkki at gmail.com>
Date:   Thu Jun 19 03:48:42 2014 +0300

    AGESA: Move config parameters for non-volatile S3 data
    
    These parameters are not specific to the southbridge device, but
    the implementation of S3 storage defined by CPU code.
    
    Change-Id: Ic341cc2b7669cf8e3e920c48473826ec03fc7d8d
    Signed-off-by: Kyösti Mälkki <kyosti.malkki at gmail.com>
---
 src/cpu/amd/agesa/Kconfig                |  9 +++++++++
 src/cpu/amd/agesa/Makefile.inc           | 15 +++++++++++++++
 src/southbridge/amd/Makefile.inc         | 17 -----------------
 src/southbridge/amd/agesa/hudson/Kconfig | 16 ----------------
 src/southbridge/amd/cimx/sb700/Kconfig   | 16 ----------------
 src/southbridge/amd/cimx/sb800/Kconfig   | 16 ----------------
 src/southbridge/amd/cimx/sb900/Kconfig   | 16 ----------------
 7 files changed, 24 insertions(+), 81 deletions(-)

diff --git a/src/cpu/amd/agesa/Kconfig b/src/cpu/amd/agesa/Kconfig
index 21f0c6f..b53e4b0 100644
--- a/src/cpu/amd/agesa/Kconfig
+++ b/src/cpu/amd/agesa/Kconfig
@@ -66,6 +66,15 @@ config DCACHE_RAM_BASE
 config DCACHE_RAM_SIZE
 	hex
 	default 0x10000
+
+config S3_DATA_POS
+	hex
+	default 0xFFFF0000
+
+config S3_DATA_SIZE
+	int
+	default 32768
+
 endif # CPU_AMD_AGESA
 
 source src/cpu/amd/agesa/family10/Kconfig
diff --git a/src/cpu/amd/agesa/Makefile.inc b/src/cpu/amd/agesa/Makefile.inc
index 4dfb173..f403d30 100644
--- a/src/cpu/amd/agesa/Makefile.inc
+++ b/src/cpu/amd/agesa/Makefile.inc
@@ -29,3 +29,18 @@ cpu_incs += $(src)/cpu/amd/agesa/cache_as_ram.inc
 
 romstage-y += heapmanager.c
 ramstage-y += heapmanager.c
+
+ifeq ($(CONFIG_HAVE_ACPI_RESUME), y)
+
+$(obj)/coreboot_s3nv.rom: $(obj)/config.h
+	echo "    S3 NVRAM   $(CONFIG_S3_DATA_POS) (S3 storage area)"
+	# force C locale, so cygwin awk doesn't try to interpret the 0xff below as UTF-8 (or worse)
+	printf %d $(CONFIG_S3_DATA_SIZE) | LC_ALL=C awk '{for (i=0; i<$$1; i++) {printf "%c", 255}}' > $@.tmp
+	mv $@.tmp $@
+
+cbfs-files-y += s3nv
+s3nv-file := $(obj)/coreboot_s3nv.rom
+s3nv-position := $(CONFIG_S3_DATA_POS)
+s3nv-type := raw
+
+endif # CONFIG_HAVE_ACPI_RESUME == y
diff --git a/src/southbridge/amd/Makefile.inc b/src/southbridge/amd/Makefile.inc
index 9ec0171..e2f3f9c 100644
--- a/src/southbridge/amd/Makefile.inc
+++ b/src/southbridge/amd/Makefile.inc
@@ -16,20 +16,3 @@ subdirs-$(CONFIG_SOUTHBRIDGE_AMD_CIMX_SB800) += cimx
 subdirs-$(CONFIG_SOUTHBRIDGE_AMD_CIMX_SB900) += cimx
 subdirs-$(CONFIG_SOUTHBRIDGE_AMD_AGESA_HUDSON) += agesa
 subdirs-$(CONFIG_SOUTHBRIDGE_AMD_AGESA_YANGTZE) += agesa
-
-ifeq ($(CONFIG_HAVE_ACPI_RESUME), y)
-ifeq ($(CONFIG_CPU_AMD_AGESA), y)
-
-$(obj)/coreboot_s3nv.rom: $(obj)/config.h
-	echo "    S3 NVRAM   $(CONFIG_S3_DATA_POS) (S3 storage area)"
-	# force C locale, so cygwin awk doesn't try to interpret the 0xff below as UTF-8 (or worse)
-	printf %d $(CONFIG_S3_DATA_SIZE) | LC_ALL=C awk '{for (i=0; i<$$1; i++) {printf "%c", 255}}' > $@.tmp
-	mv $@.tmp $@
-
-cbfs-files-y += s3nv
-s3nv-file := $(obj)/coreboot_s3nv.rom
-s3nv-position := $(CONFIG_S3_DATA_POS)
-s3nv-type := raw
-
-endif # CONFIG_CPU_AMD_AGESA == y
-endif # CONFIG_HAVE_ACPI_RESUME == y
diff --git a/src/southbridge/amd/agesa/hudson/Kconfig b/src/southbridge/amd/agesa/hudson/Kconfig
index 9e21b84..a0c68a3 100644
--- a/src/southbridge/amd/agesa/hudson/Kconfig
+++ b/src/southbridge/amd/agesa/hudson/Kconfig
@@ -215,22 +215,6 @@ config RAID_MISC_ROM_POSITION
 	  The CONFIG_ROM_SIZE must larger than 0x100000.
 endif # HUDSON_SATA_RAID
 
-config S3_DATA_POS
-	hex "S3 volatile storage position"
-	default 0xFFFF0000
-	depends on HAVE_ACPI_RESUME
-	help
-	  For a system with S3 feature, the BIOS needs to save some data to
-	  non-volatile storage at cold boot stage.
-
-config S3_DATA_SIZE
-	int "S3 volatile storage size"
-	default 32768
-	depends on HAVE_ACPI_RESUME
-	help
-	  For a system with S3 feature, the BIOS needs to save some data to
-	  non-volatile storage at cold boot stage.
-
 config HUDSON_LEGACY_FREE
 	bool "System is legacy free"
 	help
diff --git a/src/southbridge/amd/cimx/sb700/Kconfig b/src/southbridge/amd/cimx/sb700/Kconfig
index d8bad86..a4f9aa0 100644
--- a/src/southbridge/amd/cimx/sb700/Kconfig
+++ b/src/southbridge/amd/cimx/sb700/Kconfig
@@ -67,21 +67,5 @@ config REDIRECT_SBCIMX_TRACE_TO_SERIAL
 
 	  Warning: Only enable this option when debuging or tracing AMD CIMX code.
 
-config S3_DATA_POS
-	hex "S3 volatile storage position"
-	default 0xFFFF0000
-	depends on HAVE_ACPI_RESUME
-	help
-	  For a system with S3 feature, the BIOS needs to save some data to
-	  non-volatile storage at cold boot stage.
-
-config S3_DATA_SIZE
-	int "S3 volatile storage size"
-	default 32768
-	depends on HAVE_ACPI_RESUME
-	help
-	  For a system with S3 feature, the BIOS needs to save some data to
-	  non-volatile storage at cold boot stage.
-
 endif #SOUTHBRIDGE_AMD_CIMX_SB700
 
diff --git a/src/southbridge/amd/cimx/sb800/Kconfig b/src/southbridge/amd/cimx/sb800/Kconfig
index 832655d..ac25e89 100644
--- a/src/southbridge/amd/cimx/sb800/Kconfig
+++ b/src/southbridge/amd/cimx/sb800/Kconfig
@@ -124,22 +124,6 @@ config RAID_MISC_ROM_POSITION
 
 endif
 
-config S3_DATA_POS
-	hex "S3 volatile storage position"
-	default 0xFFFF0000
-	depends on HAVE_ACPI_RESUME
-	help
-	  For a system with S3 feature, the BIOS needs to save some data to
-	  non-volatile storage at cold boot stage.
-
-config S3_DATA_SIZE
-	int "S3 volatile storage size"
-	default 32768
-	depends on HAVE_ACPI_RESUME
-	help
-	  For a system with S3 feature, the BIOS needs to save some data to
-	  non-volatile storage at cold boot stage.
-
 config SB800_IMC_FWM
 	bool "Add IMC firmware"
 	default n
diff --git a/src/southbridge/amd/cimx/sb900/Kconfig b/src/southbridge/amd/cimx/sb900/Kconfig
index 5d3b0a1..3bef95a 100644
--- a/src/southbridge/amd/cimx/sb900/Kconfig
+++ b/src/southbridge/amd/cimx/sb900/Kconfig
@@ -54,21 +54,5 @@ config BOOTBLOCK_SOUTHBRIDGE_INIT
         string
         default "southbridge/amd/cimx/sb900/bootblock.c"
 
-config S3_DATA_POS
-	hex "S3 volatile storage position"
-	default 0xFFFF0000
-	depends on HAVE_ACPI_RESUME
-	help
-	  For a system with S3 feature, the BIOS needs to save some data to
-	  non-volatile storage at cold boot stage.
-
-config S3_DATA_SIZE
-	int "S3 volatile storage size"
-	default 32768
-	depends on HAVE_ACPI_RESUME
-	help
-	  For a system with S3 feature, the BIOS needs to save some data to
-	  non-volatile storage at cold boot stage.
-
 endif #SOUTHBRIDGE_AMD_CIMX_SB900
 



More information about the coreboot-gerrit mailing list