@@ -39,7 +39,7 @@ $(obj)/csumpartialcopy.o: $(obj)/csumpartialcopygeneric.S
$(obj)/csumpartialcopyuser.o: $(obj)/csumpartialcopygeneric.S
ifeq ($(CONFIG_KERNEL_MODE_NEON),y)
- NEON_FLAGS := -mfloat-abi=softfp -mfpu=neon
+ NEON_FLAGS := -mfloat-abi=softfp -mfpu=neon -march=armv7-a
CFLAGS_xor-neon.o += $(NEON_FLAGS)
obj-$(CONFIG_XOR_BLOCKS) += xor-neon.o
endif
@@ -23,7 +23,7 @@ endif
ifeq ($(CONFIG_KERNEL_MODE_NEON),y)
NEON_FLAGS := -ffreestanding
ifeq ($(ARCH),arm)
-NEON_FLAGS += -mfloat-abi=softfp -mfpu=neon
+NEON_FLAGS += -mfloat-abi=softfp -mfpu=neon -march=armv7-a
endif
ifeq ($(ARCH),arm64)
CFLAGS_REMOVE_neon1.o += -mgeneral-regs-only
clang ignores the -mfpu=neon flag when building with -march=armv6: In file included from lib/raid6/neon1.c:27: clang/3.8.0/include/arm_neon.h:28:2: error: "NEON support not enabled" There is no real need to build the file with -march=armv6 in a multi-CPU enabled kernel, as nothing in here will ever get called on an ARMv6 CPU. Adding -march=armv7 doesn't hurt and can only improve the code quality. Signed-off-by: Arnd Bergmann <arnd@arndb.de> --- arch/arm/lib/Makefile | 2 +- lib/raid6/Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -- 2.7.0