[REVIEW] ARM: always build xscale-cp0 for ARMv5TE
In a multiplatform configuration, we may end up building a kernel
for both Marvell PJ1 and an ARMv4 CPU implementation. In that
case, the xscale-cp0 code is built with gcc -march=armv4{,t},
which results in a build error from the coprocessor instructions.
Since we know this code will only have to run on an actual xscale
processor, we can simply build the entire file for ARMv5TE.
[FIXME: we actually call the late_initcall on all CPUs, so
this seems unsafe].
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
diff --git a/arch/arm/kernel/Makefile b/arch/arm/kernel/Makefile
index 91bf5f8..b684eeb 100644
--- a/arch/arm/kernel/Makefile
+++ b/arch/arm/kernel/Makefile
@@ -76,6 +76,7 @@
obj-$(CONFIG_CPU_XSCALE) += xscale-cp0.o
obj-$(CONFIG_CPU_XSC3) += xscale-cp0.o
obj-$(CONFIG_CPU_MOHAWK) += xscale-cp0.o
+CFLAGS_xscale-cp0.o += -march=armv5te
obj-$(CONFIG_CPU_PJ4) += pj4-cp0.o
CFLAGS_pj4-cp0.o += -march=armv7-a
obj-$(CONFIG_IWMMXT) += iwmmxt.o