bpf: Fix LRU NMI/tracepoint re-entry deadlock
Status from this message: This series was applied to bpf/bpf-next.git (master)
Get series with b4
b4 am [email protected] change-id 20260519-lru_map_spin-8e20dabbf460Versions newest first
- v3 Latest3 patches 1 replyApplied 3/3
- v2 RFC3 patches 2 repliesSuperseded
- v1 RFC3 patches 0 repliesSuperseded
Changes in v3 from the cover letter
- Removed RFC tag
- Link to v2: https://patch.msgid.link/[email protected]
Patches in v3 All 3 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | bpf: Fix NMI/tracepoint re-entry deadlock on lru lockskernel/ kernel/ | +119 | 1 reply | Applied |
| 2/3 | Documentation/bpf: Refresh map_lru_hash_update.dot for rqspinlockDocumentation/ | +42 | 0 replies | Applied |
| 3/3 | selftests/bpf: Stress LRU rqspinlock recovery pathstools/ tools/ | +276 | 0 replies | Applied |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v3 yet.
Cover letter [PATCH bpf-next v3 0/3] bpf: Fix LRU NMI/tracepoint re-entry deadlock
This series fixes AA-deadlocks where NMI and tracepoint BPF programs re-enter the per-CPU or global LRU lock already held on the same CPU (syzbot c69a0a2c816716f1e0d5, 18b26edb69b2e19f3b33).
Patch 1 converts every LRU lock site to rqspinlock_t and adds explicit recovery for some failures so no node leaks.
Patch 2 refreshes Documentation/bpf/map_lru_hash_update.dot to show the new rqspinlock failure exits and recovery routes.
Patch 3 introduces a stress test.
---
Changes in v3:
- Removed RFC tag
- Link to v2: https://patch.msgid.link/[email protected]
Changes in v2:
- Patch 1: __bpf_lru_node_move_in() now clears pending_free only when moving to the FREE list.
- Patch 3: address sashiko's feedback.
- Link to v1: https://patch.msgid.link/[email protected]
---
Mykyta Yatsenko (3):
bpf: Fix NMI/tracepoint re-entry deadlock on lru locks Documentation/bpf: Refresh map_lru_hash_update.dot for rqspinlock selftests/bpf: Stress LRU rqspinlock recovery paths
Documentation/bpf/map_lru_hash_update.dot | 44 +++- kernel/bpf/bpf_lru_list.c | 165 ++++++++------ kernel/bpf/bpf_lru_list.h | 25 ++- .../selftests/bpf/prog_tests/lru_lock_nmi.c | 243 +++++++++++++++++++++ tools/testing/selftests/bpf/progs/lru_lock_nmi.c | 33 +++ 5 files changed, 437 insertions(+), 73 deletions(-)
---
base-commit: 245da8192c073820390f7fa1cc1e834b32119bce
change-id: 20260519-lru_map_spin-8e20dabbf460
Best regards,
Signature · 1 line
Mykyta Yatsenko <[email protected]>