summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/bin
diff options
context:
space:
mode:
authorKumar Kartikeya Dwivedi <memxor@gmail.com>2026-08-04 11:34:04 +0200
committerKumar Kartikeya Dwivedi <memxor@gmail.com>2026-08-04 11:34:04 +0200
commit7f333f85f83da9a20a60a1d8bf518c4ae0818e5a (patch)
tree4ade5cdc840234563d248a23db0752fa229eb58b /tools/perf/scripts/python/bin
parent457d4ecb47aaf7a2cb46aaadd76e8c812e4f3c9e (diff)
parentbb2df6fd891d6332cc180d198914e9f40ada50e8 (diff)
Merge branch 'bpf-invalidate-rcu-pointers-after-final-spin-unlock'
Ning Ding says: ==================== bpf: Invalidate RCU pointers after final spin unlock In a sleepable BPF program, a spin lock can provide the only RCU protection for a kptr. The final spin unlock ends that protection, but the verifier leaves the pointer valid. Another CPU can then free the object before the pointer is used. A capability-limited runtime PoC triggered a KASAN-confirmed task_struct use-after-free. Patch 1 invalidates RCU-protected pointers only when an unlock leaves the final RCU-protected context. Patch 2 adds a negative sleepable test and positive controls for non-sleepable and explicit-RCU contexts. Testing used fresh QEMU/KVM guests with KASAN enabled. The patched focused test passed all three expected outcomes. The full task_kfunc test passed all 39 subtests, and the selected RCU, refcount, and spin-lock group had no failures. --- v2: - Rebase onto bpf-next commit 60781269e26c. - Target bpf-next and split the fix from its selftests, as requested. - Add positive controls for RCU contexts that remain valid after unlock. v1: https://lore.kernel.org/r/20260802231248.2781334-1-dingning04@gmail.com ==================== Link: https://patch.msgid.link/20260803112615.3362122-1-dingning04@gmail.com Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions