]> git.ipfire.org Git - thirdparty/linux.git/commit
rv: Convert the opid monitor to a hybrid automaton
authorGabriele Monaco <gmonaco@redhat.com>
Mon, 30 Mar 2026 11:10:05 +0000 (13:10 +0200)
committerGabriele Monaco <gmonaco@redhat.com>
Tue, 31 Mar 2026 14:47:17 +0000 (16:47 +0200)
commit2b406fdb33387713cb9f880e58e5ff09901c6ebc
tree3920d200b359369fb1d943e150572a5002669da6
parent13578a087152b85e53b1fa11639c814cb427808a
rv: Convert the opid monitor to a hybrid automaton

The opid monitor validates that wakeup and need_resched events only
occur with interrupts and preemption disabled by following the
preemptirq tracepoints.
As reported in [1], those tracepoints might be inaccurate in some
situations (e.g. NMIs).

Since the monitor doesn't validate other ordering properties, remove the
dependency on preemptirq tracepoints and convert the monitor to a hybrid
automaton to validate the constraint during event handling.
This makes the monitor more robust by also removing the workaround for
interrupts missing the preemption tracepoints, which was working on
PREEMPT_RT only and allows the monitor to be built on kernels without
the preemptirqs tracepoints.

[1] - https://lore.kernel.org/lkml/20250625120823.60600-1-gmonaco@redhat.com

Reviewed-by: Nam Cao <namcao@linutronix.de>
Link: https://lore.kernel.org/r/20260330111010.153663-8-gmonaco@redhat.com
Signed-off-by: Gabriele Monaco <gmonaco@redhat.com>
Documentation/trace/rv/monitor_sched.rst
kernel/trace/rv/monitors/opid/Kconfig
kernel/trace/rv/monitors/opid/opid.c
kernel/trace/rv/monitors/opid/opid.h
kernel/trace/rv/monitors/opid/opid_trace.h
kernel/trace/rv/rv_trace.h
tools/verification/models/sched/opid.dot