Commit d2098b44 authored by Peter Zijlstra's avatar Peter Zijlstra Committed by Paul E. McKenney
Browse files

rcu,ftrace: Fix ftrace recursion



Kim reported that perf-ftrace made his box unhappy. It turns out that
commit:

  ff5c4f5c ("rcu/tree: Mark the idle relevant functions noinstr")

removed one too many notrace qualifiers, probably due to there not being
a helpful comment.

This commit therefore reinstates the notrace and adds a comment to avoid
losing it again.

[ paulmck: Apply Steven Rostedt's feedback on the comment. ]
Fixes: ff5c4f5c ("rcu/tree: Mark the idle relevant functions noinstr")
Reported-by: default avatarKim Phillips <kim.phillips@amd.com>
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: default avatarPaul E. McKenney <paulmck@kernel.org>
parent 7c47ee5a
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -1093,8 +1093,11 @@ static void rcu_disable_urgency_upon_qs(struct rcu_data *rdp)
 * CPU can safely enter RCU read-side critical sections.  In other words,
 * if the current CPU is not in its idle loop or is in an interrupt or
 * NMI handler, return true.
 *
 * Make notrace because it can be called by the internal functions of
 * ftrace, and making this notrace removes unnecessary recursion calls.
 */
bool rcu_is_watching(void)
notrace bool rcu_is_watching(void)
{
	bool ret;