From: Lai Jiangshan Date: Thu, 27 Nov 2008 02:21:46 +0000 (+0800) Subject: ftrace: prevent recursion X-Git-Tag: v2.6.28-rc7~44^2 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=4f5a7f40ddbae98569acbb99118a98570315579c;p=linux-2.6-omap-h63xx.git ftrace: prevent recursion Impact: prevent unnecessary stack recursion if the resched flag was set before we entered, then don't reschedule. Signed-off-by: Lai Jiangshan Acked-by: Steven Rostedt Signed-off-by: Ingo Molnar --- diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c index f780e9552f9..668bbb5ef2b 100644 --- a/kernel/trace/ring_buffer.c +++ b/kernel/trace/ring_buffer.c @@ -1215,7 +1215,7 @@ ring_buffer_lock_reserve(struct ring_buffer *buffer, out: if (resched) - preempt_enable_notrace(); + preempt_enable_no_resched_notrace(); else preempt_enable_notrace(); return NULL;