From: Lai Jiangshan Date: Thu, 27 Nov 2008 02:21:46 +0000 (+0800) Subject: ftrace: prevent recursion X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=4f5a7f40ddbae98569acbb99118a98570315579c;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.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 f780e9552f91..668bbb5ef2bd 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;