From patchwork Mon Apr 12 14:16:30 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Move cpu includes to cpus Date: Mon, 12 Apr 2010 14:16:30 -0000 From: Patrick Georgi X-Patchwork-Id: 1227 Message-Id: <4BC32B3E.1020901@georgi-clan.de> To: coreboot@coreboot.org Hi, attached patch moves the CPU specific includes from src/arch/i386/Makefile.inc to the respective CPU directories. One exception is the tyan/s2735 rule, as this is a weird situation: CAR code for exactly one board. As soon as sibling boards are identified and CAR enabled, it would make sense to move that include out as well. For now, for the increased visibility (and because I'm a bit puzzled where a good location for that file would be), I left it there. The cpu/x86/car/cache_as_ram.lds is useless, so deleting it is also part of this change (not tracked in this patch) Signed-off-by: Patrick Georgi Acked-by: Stefan Reinauer Index: src/cpu/via/model_c7/Makefile.inc =================================================================== --- src/cpu/via/model_c7/Makefile.inc (revision 5408) +++ src/cpu/via/model_c7/Makefile.inc (working copy) @@ -6,3 +6,5 @@ subdirs-y += ../../intel/microcode driver-y += model_c7_init.o + +cpu_incs += $(src)/cpu/via/car/cache_as_ram.inc Index: src/cpu/amd/model_gx1/Makefile.inc =================================================================== --- src/cpu/amd/model_gx1/Makefile.inc (revision 5408) +++ src/cpu/amd/model_gx1/Makefile.inc (working copy) @@ -23,3 +23,6 @@ subdirs-y += ../../x86/cache subdirs-y += ../../x86/smm driver-y += model_gx1_init.o + +cpu_incs += $(src)/cpu/amd/model_gx1/cpu_setup.inc +cpu_incs += $(src)/cpu/amd/model_gx1/gx_setup.inc Index: src/cpu/amd/socket_S1G1/Makefile.inc =================================================================== --- src/cpu/amd/socket_S1G1/Makefile.inc (revision 5408) +++ src/cpu/amd/socket_S1G1/Makefile.inc (working copy) @@ -10,3 +10,4 @@ subdirs-y += ../../x86/smm subdirs-y += ../../x86/mtrr +cpu_incs += $(src)/cpu/amd/car/cache_as_ram.inc Index: src/cpu/amd/socket_940/Makefile.inc =================================================================== --- src/cpu/amd/socket_940/Makefile.inc (revision 5408) +++ src/cpu/amd/socket_940/Makefile.inc (working copy) @@ -8,3 +8,5 @@ subdirs-y += ../../x86/cache subdirs-y += ../../x86/mtrr subdirs-y += ../../x86/pae + +cpu_incs += $(src)/cpu/amd/car/cache_as_ram.inc Index: src/cpu/amd/socket_AM2/Makefile.inc =================================================================== --- src/cpu/amd/socket_AM2/Makefile.inc (revision 5408) +++ src/cpu/amd/socket_AM2/Makefile.inc (working copy) @@ -9,3 +9,5 @@ subdirs-y += ../../x86/mtrr subdirs-y += ../../x86/pae subdirs-y += ../../x86/smm + +cpu_incs += $(src)/cpu/amd/car/cache_as_ram.inc Index: src/cpu/amd/socket_754/Makefile.inc =================================================================== --- src/cpu/amd/socket_754/Makefile.inc (revision 5408) +++ src/cpu/amd/socket_754/Makefile.inc (working copy) @@ -8,3 +8,5 @@ subdirs-y += ../../x86/cache subdirs-y += ../../x86/mtrr subdirs-y += ../../x86/pae + +cpu_incs += $(src)/cpu/amd/car/cache_as_ram.inc Index: src/cpu/amd/socket_AM2r2/Makefile.inc =================================================================== --- src/cpu/amd/socket_AM2r2/Makefile.inc (revision 5408) +++ src/cpu/amd/socket_AM2r2/Makefile.inc (working copy) @@ -9,3 +9,5 @@ subdirs-y += ../../x86/pae subdirs-y += ../../x86/smm subdirs-y += ../../x86/mtrr + +cpu_incs += $(src)/cpu/amd/car/cache_as_ram.inc Index: src/cpu/amd/socket_939/Makefile.inc =================================================================== --- src/cpu/amd/socket_939/Makefile.inc (revision 5408) +++ src/cpu/amd/socket_939/Makefile.inc (working copy) @@ -8,3 +8,5 @@ subdirs-y += ../../x86/cache subdirs-y += ../../x86/mtrr subdirs-y += ../../x86/pae + +cpu_incs += $(src)/cpu/amd/car/cache_as_ram.inc Index: src/cpu/amd/socket_F/Makefile.inc =================================================================== --- src/cpu/amd/socket_F/Makefile.inc (revision 5408) +++ src/cpu/amd/socket_F/Makefile.inc (working copy) @@ -9,3 +9,5 @@ subdirs-y += ../../x86/mtrr subdirs-y += ../../x86/pae subdirs-y += ../../x86/smm + +cpu_incs += $(src)/cpu/amd/car/cache_as_ram.inc Index: src/cpu/amd/model_lx/Makefile.inc =================================================================== --- src/cpu/amd/model_lx/Makefile.inc (revision 5408) +++ src/cpu/amd/model_lx/Makefile.inc (working copy) @@ -6,3 +6,5 @@ driver-y += model_lx_init.o obj-y += cpubug.o obj-y += vsmsetup.o + +cpu_incs += $(src)/cpu/amd/model_lx/cache_as_ram.inc Index: src/cpu/amd/socket_F_1207/Makefile.inc =================================================================== --- src/cpu/amd/socket_F_1207/Makefile.inc (revision 5408) +++ src/cpu/amd/socket_F_1207/Makefile.inc (working copy) @@ -9,3 +9,5 @@ subdirs-y += ../../x86/mtrr subdirs-y += ../../x86/pae subdirs-y += ../../x86/smm + +cpu_incs += $(src)/cpu/amd/car/cache_as_ram.inc Index: src/cpu/intel/model_6ex/Makefile.inc =================================================================== --- src/cpu/intel/model_6ex/Makefile.inc (revision 5408) +++ src/cpu/intel/model_6ex/Makefile.inc (working copy) @@ -1 +1,3 @@ driver-y += model_6ex_init.o + +cpu_incs += $(src)/cpu/intel/model_6ex/cache_as_ram.inc Index: src/cpu/intel/socket_mFCBGA479/Makefile.inc =================================================================== --- src/cpu/intel/socket_mFCBGA479/Makefile.inc (revision 5408) +++ src/cpu/intel/socket_mFCBGA479/Makefile.inc (working copy) @@ -6,3 +6,5 @@ subdirs-y += ../../x86/cache subdirs-y += ../../x86/smm subdirs-y += ../microcode + +cpu_incs += $(src)/cpu/x86/car/cache_as_ram.inc Index: src/cpu/intel/bga956/Makefile.inc =================================================================== --- src/cpu/intel/bga956/Makefile.inc (revision 5408) +++ src/cpu/intel/bga956/Makefile.inc (working copy) @@ -8,3 +8,5 @@ subdirs-y += ../microcode subdirs-y += ../hyperthreading +# Use Intel Core (not Core 2) code for CAR init, any CPU might be used. +cpu_incs += $(src)/cpu/intel/model_6ex/cache_as_ram.inc Index: src/cpu/intel/model_106cx/Makefile.inc =================================================================== --- src/cpu/intel/model_106cx/Makefile.inc (revision 5408) +++ src/cpu/intel/model_106cx/Makefile.inc (working copy) @@ -1 +1,3 @@ driver-y += model_106cx_init.o + +cpu_incs += $(src)/cpu/intel/model_106cx/cache_as_ram.inc Index: src/arch/i386/Makefile.inc =================================================================== --- src/arch/i386/Makefile.inc (revision 5408) +++ src/arch/i386/Makefile.inc (working copy) @@ -117,61 +117,15 @@ endif crt0s += $(src)/cpu/x86/fpu_enable.inc -ifeq ($(CONFIG_CPU_AMD_GX1),y) -crt0s += $(src)/cpu/amd/model_gx1/cpu_setup.inc -crt0s += $(src)/cpu/amd/model_gx1/gx_setup.inc -endif ifeq ($(CONFIG_SSE),y) crt0s += $(src)/cpu/x86/sse_enable.inc endif -ifeq ($(CONFIG_CPU_AMD_LX),y) -crt0s += $(src)/cpu/amd/model_lx/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_AMD_SOCKET_F),y) -crt0s += $(src)/cpu/amd/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_AMD_SOCKET_F_1207),y) -crt0s += $(src)/cpu/amd/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_AMD_SOCKET_AM2R2),y) -crt0s += $(src)/cpu/amd/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_AMD_SOCKET_AM2),y) -crt0s += $(src)/cpu/amd/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_AMD_SOCKET_S1G1),y) -crt0s += $(src)/cpu/amd/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_AMD_SOCKET_754),y) -crt0s += $(src)/cpu/amd/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_AMD_SOCKET_939),y) -crt0s += $(src)/cpu/amd/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_AMD_SOCKET_940),y) -crt0s += $(src)/cpu/amd/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_INTEL_ATOM_230),y) -crt0s += $(src)/cpu/intel/model_106cx/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_INTEL_CORE),y) -crt0s += $(src)/cpu/intel/model_6ex/cache_as_ram.inc -endif -# Use Intel Core (not Core 2) code for CAR init, any CPU might be used. -ifeq ($(CONFIG_CPU_INTEL_SOCKET_BGA956),y) -crt0s += $(src)/cpu/intel/model_6ex/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_INTEL_SOCKET_MFCBGA479),y) -crt0s += $(src)/cpu/x86/car/cache_as_ram.inc -endif -ifeq ($(CONFIG_CPU_VIA_C7),y) -crt0s += $(src)/cpu/via/car/cache_as_ram.inc -endif +crt0s += $(cpu_incs) + # who else could use this? ifeq ($(CONFIG_BOARD_TYAN_S2735),y) crt0s += $(src)/cpu/x86/car/cache_as_ram.inc -ldscripts += $(src)/cpu/x86/car/cache_as_ram.lds endif ifeq ($(CONFIG_LLSHELL),y)