Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

tracing: make PREEMPTIRQ_EVENTS depend on TRACING

When CONFIG_TRACING is disabled, the new preemptirq events tracer
produces a build failure:

In file included from kernel/trace/trace_irqsoff.c:17:0:
kernel/trace/trace.h: In function 'trace_test_and_set_recursion':
kernel/trace/trace.h:542:28: error: 'struct task_struct' has no member named 'trace_recursion'

Adding an explicit dependency avoids the broken configuration.

Link: http://lkml.kernel.org/r/20171103104031.270375-1-arnd@arndb.de

Fixes: d59158162e03 ("tracing: Add support for preempt and irq enable/disable events")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>

authored by

Arnd Bergmann and committed by
Steven Rostedt (VMware)
2dde6b00 90e406f9

+1
+1
kernel/trace/Kconfig
··· 164 164 bool "Enable trace events for preempt and irq disable/enable" 165 165 select TRACE_IRQFLAGS 166 166 depends on DEBUG_PREEMPT || !PROVE_LOCKING 167 + depends on TRACING 167 168 default n 168 169 help 169 170 Enable tracing of disable and enable events for preemption and irqs.