On Fri, Apr 16, 2021 at 02:29:36PM -0700, Josh Don wrote: > From: Paul Turner <p...@google.com> > > CPU scheduler marks need_resched flag to signal a schedule() on a > particular CPU. But, schedule() may not happen immediately in cases > where the current task is executing in the kernel mode (no > preemption state) for extended periods of time. > > This patch adds a warn_on if need_resched is pending for more than the > time specified in sysctl resched_latency_warn_ms. If it goes off, it is > likely that there is a missing cond_resched() somewhere. Monitoring is > done via the tick and the accuracy is hence limited to jiffy scale. This > also means that we won't trigger the warning if the tick is disabled. > > This feature (LATENCY_WARN) is default disabled. > > Signed-off-by: Paul Turner <p...@google.com> > Signed-off-by: Josh Don <josh...@google.com> > Signed-off-by: Peter Zijlstra (Intel) <pet...@infradead.org> > Link: https://lkml.kernel.org/r/20210323035706.572953-1-josh...@google.com
Thanks!