Re: [PATCH] sched: Further restrict the preemption modes

Steven Rostedt
2026-02-26T00:48:15Z

On Wed, 25 Feb 2026 11:53:45 +0100
Peter Zijlstra <peterz@infradead.org> wrote:

> Oh, that reminds me, Steve, would it make sense to have
> task_struct::se.sum_exec_runtime as a trace-clock?

That's unique per task right? As tracing is global it requires the
clock to be monotonic, and I'm guessing a single sched_switch will
break that.

Now if one wants to trace how long kernel paths are, I'm sure we could
trivially make a new tracer to do so.

echo max_kernel_time > current_tracer

or something like that, that could act like a latency tracer that
monitors how long any kernel thread runs without being preempted.

-- Steve