summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMykyta Yatsenko <yatsenko@meta.com>2026-01-31 18:54:01 -0800
committerAndrii Nakryiko <andrii@kernel.org>2026-02-03 16:58:47 -0800
commit083c5a4babad4af89dd07e2cc5f7004343d4c1f0 (patch)
treed989124767e6edadee9ad8d4ccf06459eeaee622 /scripts
parentfe9d205cec8ccdd13171a056257101374306e802 (diff)
selftests/bpf: Add timer stress test in NMI context
Add stress tests for BPF timers that run in NMI context using perf_event programs attached to PERF_COUNT_HW_CPU_CYCLES. The tests cover three scenarios: - nmi_race: Tests concurrent timer start and async cancel operations - nmi_update: Tests updating a map element (effectively deleting and inserting new for array map) from within a timer callback - nmi_cancel: Tests timer self-cancellation attempt. A common test_common() helper is used to share timer setup logic across all test modes. The tests spawn multiple threads in a child process to generate perf events, which trigger the BPF programs in NMI context. Hit counters verify that the NMI code paths were actually exercised. Signed-off-by: Mykyta Yatsenko <yatsenko@meta.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20260201025403.66625-8-alexei.starovoitov@gmail.com
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions