tracing_gen_ctx(), tracing_gen_ctx_flags() and tracing_gen_ctx_dec() are called by ftrace callbacks before they take any recursion protection, for example function_test_events_call() in kernel/trace/trace_events.c, which is built with -pg when CONFIG_FUNCTION_SELF_TRACING=y. They are plain inline functions, so an out-of-line copy is untraced only because inline implies notrace.
Mark them notrace explicitly. No functional change. Assisted-by: Claude:claude-opus-5 Signed-off-by: Song Liu <[email protected]> --- include/linux/trace_events.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/linux/trace_events.h b/include/linux/trace_events.h index 5cbd09c8be8d..15990e23a662 100644 --- a/include/linux/trace_events.h +++ b/include/linux/trace_events.h @@ -197,13 +197,13 @@ enum trace_flag_type { TRACE_FLAG_BH_OFF = 0x80, }; -static inline unsigned int tracing_gen_ctx_flags(unsigned long irqflags) +static inline unsigned int notrace tracing_gen_ctx_flags(unsigned long irqflags) { unsigned int irq_status = irqs_disabled_flags(irqflags) ? TRACE_FLAG_IRQS_OFF : 0; return tracing_gen_ctx_irq_test(irq_status); } -static inline unsigned int tracing_gen_ctx(void) +static inline unsigned int notrace tracing_gen_ctx(void) { unsigned long irqflags; @@ -211,7 +211,7 @@ static inline unsigned int tracing_gen_ctx(void) return tracing_gen_ctx_flags(irqflags); } -static inline unsigned int tracing_gen_ctx_dec(void) +static inline unsigned int notrace tracing_gen_ctx_dec(void) { unsigned int trace_ctx; -- 2.53.0-Meta
