[RFC PATCH 12/13] ARC: build: inhibit ZOL generation by compiler

Sergey Matyukevich geomatsi at gmail.com
Tue Feb 22 06:15:05 PST 2022


From: Vineet Gupta <vgupta at kernel.org>

Inhibit ZOL generation by compiler if configuration states
the lack of it. This is done before we remove the ZOL regs
save/restore in entry code

Signed-off-by: Vineet Gupta <vgupta at kernel.org>
---
 arch/arc/Makefile | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arc/Makefile b/arch/arc/Makefile
index ec0f672bcee6..98a03c8d719c 100644
--- a/arch/arc/Makefile
+++ b/arch/arc/Makefile
@@ -44,6 +44,8 @@ cflags-y				+= -Wa,-I$(srctree)/arch/arc/include
 cflags-$(CONFIG_ARC_HAS_LLSC)		+= -mlock
 cflags-$(CONFIG_ARC_HAS_SWAPE)		+= -mswape
 
+cflags-$(CONFIG_ARC_LACKS_ZOL)		+= -fno-branch-count-reg
+
 ifdef CONFIG_ISA_ARCV2
 
 ifdef CONFIG_ARC_USE_UNALIGNED_MEM_ACCESS
-- 
2.25.1




More information about the linux-snps-arc mailing list