Skip to content

Commit 978defe

Browse files
committed
tracing: Do a WARN_ON() if start_thread() in hwlat is called when thread exists
The start function of the hwlat tracer should never be called when the hwlat thread already exists. If it is called, do a WARN_ON(). Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
1 parent 82fbc8c commit 978defe

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎kernel/trace/trace_hwlat.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,7 @@ static int start_kthread(struct trace_array *tr)
354354
struct task_struct *kthread;
355355
int next_cpu;
356356

357-
if (hwlat_kthread)
357+
if (WARN_ON(hwlat_kthread))
358358
return 0;
359359

360360
/* Just pick the first CPU on first iteration */

0 commit comments

Comments
 (0)