[PATCH bpf v4 0/1] Fix bpf_link grace period wait for tracepoints

Kumar Kartikeya Dwivedi
2026-03-31T21:10:24Z

A recent change to non-faultable tracepoints switched from
preempt-disabled critical sections to SRCU-fast, which breaks
assumptions in the bpf_link_free() path. Use call_srcu() to fix the
breakage.

Changelog:
----------
v3 -> v4
v3: https://lore.kernel.org/bpf/20260331005215.2813492-1-memxor@gmail.com

* Introduce call_tracepoint_unregister_{atomic,syscall} instead. (Alexei, Steven)

v2 -> v3
v2: https://lore.kernel.org/bpf/20260330143102.1265391-1-memxor@gmail.com

* Introduce and switch to call_tracepoint_unregister_non_faultable(). (Steven)
* Address Andrii's comment and add Acked-by. (Andrii)
* Drop rcu_trace_implies_rcu_gp() conversion. (Alexei)

v1 -> v2
v1: https://lore.kernel.org/bpf/20260330032124.3141001-1-memxor@gmail.com

* Add Reviewed-by tags. (Paul, Puranjay)
* Adjust commit descriptions and comments to clarify intent. (Puranjay)

Kumar Kartikeya Dwivedi (1):
bpf: Fix grace period wait for tracepoint bpf_link

include/linux/bpf.h | 4 ++++
include/linux/tracepoint.h | 20 ++++++++++++++++++++
kernel/bpf/syscall.c | 25 +++++++++++++++++++++++--
3 files changed, 47 insertions(+), 2 deletions(-)

base-commit: c369299895a591d96745d6492d4888259b004a9e
--
2.52.0