compiler.h: add CC_USING_PATCHABLE_FUNCTION_ENTRY
authorSven Schnelle <svens@stackframe.org>
Wed, 5 Jun 2019 20:32:21 +0000 (22:32 +0200)
committerHelge Deller <deller@gmx.de>
Sat, 8 Jun 2019 10:56:28 +0000 (12:56 +0200)
This can be used for architectures implementing dynamic
ftrace via -fpatchable-function-entry.

Signed-off-by: Sven Schnelle <svens@stackframe.org>
Signed-off-by: Helge Deller <deller@gmx.de>
include/linux/compiler_types.h

index 19e58b9138a04db090ebf3ec787de45529fe2d64..095d55c3834db622487efac2bbfb15ed0f0417d4 100644 (file)
@@ -112,6 +112,8 @@ struct ftrace_likely_data {
 
 #if defined(CC_USING_HOTPATCH)
 #define notrace                        __attribute__((hotpatch(0, 0)))
+#elif defined(CC_USING_PATCHABLE_FUNCTION_ENTRY)
+#define notrace                        __attribute__((patchable_function_entry(0, 0)))
 #else
 #define notrace                        __attribute__((__no_instrument_function__))
 #endif