VisionFive2 Linux kernel

StarFive Tech Linux Kernel for VisionFive (JH7110) boards (mirror)

More than 9999 Commits   33 Branches   57 Tags
author: Nick Desaulniers <ndesaulniers@google.com> 2020-02-14 14:18:11 -0800 committer: Linus Torvalds <torvalds@linux-foundation.org> 2020-06-04 19:28:07 -0700 commit: 587f17018a2c6c414e41a312b002faaef60cf423 parent: 886d7de631da71e30909980fdbf318f7caade262
Commit Summary:
Kconfig: add config option for asm goto w/ outputs
Diffstat:
1 file changed, 4 insertions, 0 deletions
diff --git a/init/Kconfig b/init/Kconfig
index 2d12d38cdd88..b5294bcba61d 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -36,6 +36,10 @@ config CC_CAN_LINK
 config CC_HAS_ASM_GOTO
 	def_bool $(success,$(srctree)/scripts/gcc-goto.sh $(CC))
 
+config CC_HAS_ASM_GOTO_OUTPUT
+	depends on CC_HAS_ASM_GOTO
+	def_bool $(success,echo 'int foo(int x) { asm goto ("": "=r"(x) ::: bar); return x; bar: return 0; }' | $(CC) -x c - -c -o /dev/null)
+
 config TOOLS_SUPPORT_RELR
 	def_bool $(success,env "CC=$(CC)" "LD=$(LD)" "NM=$(NM)" "OBJCOPY=$(OBJCOPY)" $(srctree)/scripts/tools-support-relr.sh)