summaryrefslogtreecommitdiff
path: root/src/cpu
diff options
context:
space:
mode:
authorAaron Durbin <adurbin@chromium.org>2017-04-07 15:20:14 -0500
committerAaron Durbin <adurbin@chromium.org>2017-04-08 23:22:02 +0200
commitbc17cdef0d3370f10f43ef45272399e3103eb01b (patch)
treead8ddac3dd90b72ae9d6d911d9b7ac4dd4520fdd /src/cpu
parentacc599b839dff95d062883ef3a5ff6f1f9fc256c (diff)
downloadcoreboot-bc17cdef0d3370f10f43ef45272399e3103eb01b.tar.xz
arch/x86: remove CAR global migration when postcar stage is used
When a platform is using postcar stage it's by definition not tearing down cache-as-ram from within romstage prior to loading ramstage. Because of this property there's no need to migrate CAR_GLOBAL variables to cbmem. Change-Id: I7c683e1937c3397cbbba15f0f5d4be9e624ac27f Signed-off-by: Aaron Durbin <adurbin@chromium.org> Reviewed-on: https://review.coreboot.org/19215 Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Tested-by: build bot (Jenkins) Tested-by: Raptor Engineering Automated Test Stand <noreply@raptorengineeringinc.com> Reviewed-by: Furquan Shaikh <furquan@google.com> Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Diffstat (limited to 'src/cpu')
-rw-r--r--src/cpu/Kconfig9
-rw-r--r--src/cpu/x86/Makefile.inc2
2 files changed, 11 insertions, 0 deletions
diff --git a/src/cpu/Kconfig b/src/cpu/Kconfig
index 009d80cac1..915526b2dc 100644
--- a/src/cpu/Kconfig
+++ b/src/cpu/Kconfig
@@ -10,6 +10,15 @@ config CACHE_AS_RAM
bool
default !ROMCC
+config NO_CAR_GLOBAL_MIGRATION
+ bool
+ default n
+ depends on CACHE_AS_RAM
+ help
+ This option is selected if there is no need to migrate CAR globals.
+ All stages which use CAR globals can directly access the variables
+ from their linked addresses.
+
config DCACHE_RAM_BASE
hex
diff --git a/src/cpu/x86/Makefile.inc b/src/cpu/x86/Makefile.inc
index 1724a060b8..771784e6ff 100644
--- a/src/cpu/x86/Makefile.inc
+++ b/src/cpu/x86/Makefile.inc
@@ -1,6 +1,8 @@
ifeq ($(CONFIG_ARCH_ROMSTAGE_X86_32)$(CONFIG_ARCH_ROMSTAGE_X86_64),y)
+ifneq ($(CONFIG_NO_CAR_GLOBAL_MIGRATION),y)
romstage-$(CONFIG_CACHE_AS_RAM) += car.c
endif
+endif
subdirs-$(CONFIG_PARALLEL_MP) += name
ramstage-$(CONFIG_PARALLEL_MP) += mp_init.c