The wakeup tracing in sched_switch does not stop when a user disables tracing. This is because the probe_sched_wakeup() is missing the check to prevent the wakeup from being traced.
Showing the changes to kernel/trace (1 of 1 file). Show all
Unified · Split
| @@ -62,6 +62,9 @@ probe_sched_wakeup(struct rq *__rq, struct task_struct *wakee, int success) · 61 unmodified lines | ||
| 62 | 62 | pc = preempt_count(); |
| 63 | 63 | tracing_record_cmdline(current); |
| 64 | 64 | |
| 65 | + if (sched_stopped) | |
| 66 | + return; | |
| 67 | + | |
| 65 | 68 | local_irq_save(flags); |
| 66 | 69 | cpu = raw_smp_processor_id(); |
| 67 | 70 | data = ctx_trace->data[cpu]; |