]> git.itanic.dy.fi Git - linux-stable/commitdiff
ARM: 9264/1: only use -mtp=cp15 for the compiler
authorNick Desaulniers <ndesaulniers@google.com>
Mon, 24 Oct 2022 19:45:17 +0000 (20:45 +0100)
committerRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Tue, 8 Nov 2022 18:36:18 +0000 (18:36 +0000)
Avoids an error from the assembler for CONFIG_THUMB2 kernels:

clang-15: error: hardware TLS register is not supported for the thumbv4t
sub-architecture

This flag only makes sense to pass to the compiler, not the assembler.

Perhaps CFLAGS_ABI can be renamed to CPPFLAGS_ABI to reflect that they
will be passed to both the compiler and assembler for sources that
require pre-processing.

Reviewed-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
arch/arm/Makefile

index 34bf50402f820d29fe2d9ac051d6ba064fe93fcc..5fdd6b9bc7c1763d17a144366f11e062ef8edcb6 100644 (file)
@@ -111,7 +111,7 @@ CFLAGS_ABI  += -meabi gnu
 endif
 
 ifeq ($(CONFIG_CURRENT_POINTER_IN_TPIDRURO),y)
-CFLAGS_ABI     += -mtp=cp15
+KBUILD_CFLAGS  += -mtp=cp15
 endif
 
 # Accept old syntax despite ".syntax unified"