summaryrefslogtreecommitdiff
path: root/arch/arm/Makefile
diff options
context:
space:
mode:
authorLuc Van Oostenryck II <luc.vanoostenryck@gmail.com>2017-10-02 22:33:35 +0300
committerRussell King <rmk+kernel@armlinux.org.uk>2017-10-12 13:18:19 +0300
commit6042b8c7c08cad7a8bdc0456c619ae941962b40a (patch)
tree85306a91c06d3168c20a469f2af00c8a6837e47b /arch/arm/Makefile
parent195320fd6e9946a0aedeb2fd0e1ac47aa5dc81c4 (diff)
downloadlinux-6042b8c7c08cad7a8bdc0456c619ae941962b40a.tar.xz
ARM: 8701/1: fix sparse flags for build on 64bit machines
By default sparse uses the characteristics of the build machine to infer things like the wordsize. This is fine when doing native builds but for ARM it's, I suspect, very rarely the case and if the build are done on a 64bit machine we get a bunch of warnings like: 'cast truncates bits from constant value (... becomes ...)' Fix this by adding the -m32 flags for sparse. Reported-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com> Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Diffstat (limited to 'arch/arm/Makefile')
-rw-r--r--arch/arm/Makefile2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 47d3a1ab08d2..817e5cfef83a 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -131,7 +131,7 @@ endif
KBUILD_CFLAGS +=$(CFLAGS_ABI) $(CFLAGS_ISA) $(arch-y) $(tune-y) $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,)) -msoft-float -Uarm
KBUILD_AFLAGS +=$(CFLAGS_ABI) $(AFLAGS_ISA) $(arch-y) $(tune-y) -include asm/unified.h -msoft-float
-CHECKFLAGS += -D__arm__
+CHECKFLAGS += -D__arm__ -m32
#Default value
head-y := arch/arm/kernel/head$(MMUEXT).o