From: "Steven Rostedt (Red Hat)" Let the user know that the RCU safety checker for function tracing has been disabled. The checker only runs when the user specifically configures it in the kernel, and this is done to search for locations in the kernel that may be unsafe for a function trace callback to use rcu_read_lock()s. But if things like function graph tracing is started, which can live lock the machine when the checker is running, it is disabled. It would be nice if the kernel let the user know that the checker is disabled, and when it is re-enabled again. As the checker only gets disabled and re-enabled by user actions (starting and stoping the function graph tracer or the irqsoff tracer) it is fine to have a printk display that it is disabled or not. Suggested-by: Paul E. McKenney Reviewed-by: Paul E. McKenney Signed-off-by: Steven Rostedt --- kernel/trace/trace_functions.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/kernel/trace/trace_functions.c b/kernel/trace/trace_functions.c index 1dec979..57e32e6 100644 --- a/kernel/trace/trace_functions.c +++ b/kernel/trace/trace_functions.c @@ -569,6 +569,8 @@ void ftrace_unsafe_rcu_checker_disable(void) atomic_inc(&ftrace_unsafe_rcu_disabled); /* Make sure the update is seen immediately */ smp_mb__after_atomic_inc(); + pr_info("Disabled FTRACE RCU checker (%pS)\n", + __builtin_return_address(0)); } void ftrace_unsafe_rcu_checker_enable(void) @@ -576,6 +578,8 @@ void ftrace_unsafe_rcu_checker_enable(void) atomic_dec(&ftrace_unsafe_rcu_disabled); /* Make sure the update is seen immediately */ smp_mb__after_atomic_dec(); + pr_info("Enabled FTRACE RCU checker (%pS)\n", + __builtin_return_address(0)); } static DEFINE_PER_CPU(unsigned long, ftrace_rcu_func); -- 1.7.10.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/