Commit 4f5a7f40 authored by Lai Jiangshan's avatar Lai Jiangshan Committed by Ingo Molnar

ftrace: prevent recursion

Impact: prevent unnecessary stack recursion

if the resched flag was set before we entered, then don't reschedule.
Signed-off-by: default avatarLai Jiangshan <laijs@cn.fujitsu.com>
Acked-by: default avatarSteven Rostedt <rostedt@goodmis.org>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent fb91ee6c
...@@ -1215,7 +1215,7 @@ ring_buffer_lock_reserve(struct ring_buffer *buffer, ...@@ -1215,7 +1215,7 @@ ring_buffer_lock_reserve(struct ring_buffer *buffer,
out: out:
if (resched) if (resched)
preempt_enable_notrace(); preempt_enable_no_resched_notrace();
else else
preempt_enable_notrace(); preempt_enable_notrace();
return NULL; return NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment