mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] sparse doesn't support indirect_branch attribute
@ 2018-02-27 19:48 Matthew Wilcox
  2018-02-27 20:18 ` Randy Dunlap
  0 siblings, 1 reply; 9+ messages in thread
From: Matthew Wilcox @ 2018-02-27 19:48 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-kernel


Don't use __attribute__((indirect_branch)) if we're compiling with
sparse.

Signed-off-by: Matthew Wilcox <mawilcox@microsoft.com>

diff --git a/include/linux/compiler-gcc.h b/include/linux/compiler-gcc.h
index e2c7f4369eff..b6be4cc25e9d 100644
--- a/include/linux/compiler-gcc.h
+++ b/include/linux/compiler-gcc.h
@@ -93,7 +93,7 @@
 #define __weak		__attribute__((weak))
 #define __alias(symbol)	__attribute__((alias(#symbol)))
 
-#ifdef RETPOLINE
+#if defined(RETPOLINE) && !defined(__CHECKER__)
 #define __noretpoline __attribute__((indirect_branch("keep")))
 #endif
 

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2018-03-01 10:24 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-27 19:48 [PATCH] sparse doesn't support indirect_branch attribute Matthew Wilcox
2018-02-27 20:18 ` Randy Dunlap
2018-02-27 22:12   ` Linus Torvalds
2018-02-27 22:30     ` Randy Dunlap
2018-02-27 22:32       ` Linus Torvalds
2018-02-27 22:36     ` Luc Van Oostenryck
2018-02-28  1:30       ` Masahiro Yamada
2018-03-01 10:06         ` Luc Van Oostenryck
2018-03-01 10:23           ` Masahiro Yamada

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®