[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <45F579D9.7090307@redhat.com>
Date: Mon, 12 Mar 2007 17:03:37 +0100
From: Michal Schmidt <mschmidt@...hat.com>
To: Ingo Molnar <mingo@...e.hu>
CC: Thomas Gleixner <tglx@...utronix.de>,
linux-kernel <linux-kernel@...r.kernel.org>
Subject: [PATCH -rt] fix preempt count underflow in user_trace_stop
When playing with trace_user_trigger_irq in order to trace
IRQ->userspace latencies, I encountered a bug in the latency tracer. If
I have wakeup_timing enabled and attempt to stop the trace in my
userspace program, the system crashes. This is caused by an unbalanced
preempt_enable() which underflows the preempt count.
Signed-off-by: Michal Schmidt <mschmidt@...hat.com>
diff --git a/kernel/latency_trace.c b/kernel/latency_trace.c
index e07bb95..29dfb79 100644
--- a/kernel/latency_trace.c
+++ b/kernel/latency_trace.c
@@ -2396,7 +2396,6 @@ long user_trace_stop(void)
if (current != sch.task) {
__raw_spin_unlock(&sch.trace_lock);
local_irq_restore(flags);
- preempt_enable();
return -EINVAL;
}
sch.task = NULL;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists