============================================ WARNING: possible recursive locking detected 6.14.0-syzkaller-g8582d9ab3efd #0 Not tainted -------------------------------------------- udevd/6034 is trying to acquire lock: ffffc900044ea0d8 (&rb->spinlock){-.-.}-{2:2}, at: __bpf_ringbuf_reserve+0x20e/0x650 kernel/bpf/ringbuf.c:423 but task is already holding lock: ffffc900044fe0d8 (&rb->spinlock){-.-.}-{2:2}, at: __bpf_ringbuf_reserve+0x20e/0x650 kernel/bpf/ringbuf.c:423 other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&rb->spinlock); lock(&rb->spinlock); *** DEADLOCK *** May be due to missing lock nesting notation 4 locks held by udevd/6034: #0: ffffffff8ee23b78 (pcpu_lock){..-.}-{3:3}, at: free_percpu+0x2b6/0x1160 mm/percpu.c:2239 #1: ffffffff8ed3df60 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:331 [inline] #1: ffffffff8ed3df60 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:841 [inline] #1: ffffffff8ed3df60 (rcu_read_lock){....}-{1:3}, at: __bpf_trace_run kernel/trace/bpf_trace.c:2362 [inline] #1: ffffffff8ed3df60 (rcu_read_lock){....}-{1:3}, at: bpf_trace_run3+0x24e/0x5b0 kernel/trace/bpf_trace.c:2405 #2: ffffc900044fe0d8 (&rb->spinlock){-.-.}-{2:2}, at: __bpf_ringbuf_reserve+0x20e/0x650 kernel/bpf/ringbuf.c:423 #3: ffffffff8ed3df60 (rcu_read_lock){....}-{1:3}, at: trace_call_bpf+0xb9/0x8a0 kernel/trace/bpf_trace.c:-1 stack backtrace: CPU: 1 UID: 0 PID: 6034 Comm: udevd Not tainted 6.14.0-syzkaller-g8582d9ab3efd #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2025 Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120 print_deadlock_bug+0x2be/0x2d0 kernel/locking/lockdep.c:3042 check_deadlock kernel/locking/lockdep.c:3094 [inline] validate_chain+0x928/0x24e0 kernel/locking/lockdep.c:3896 __lock_acquire+0xad5/0xd80 kernel/locking/lockdep.c:5235 lock_acquire+0x116/0x2f0 kernel/locking/lockdep.c:5866 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xd8/0x130 kernel/locking/spinlock.c:162 __bpf_ringbuf_reserve+0x20e/0x650 kernel/bpf/ringbuf.c:423 ____bpf_ringbuf_reserve kernel/bpf/ringbuf.c:474 [inline] bpf_ringbuf_reserve+0x5c/0x70 kernel/bpf/ringbuf.c:466 bpf_prog_ba4789e7f2e155d6+0x36/0x53 bpf_dispatcher_nop_func include/linux/bpf.h:1316 [inline] __bpf_prog_run include/linux/filter.h:718 [inline] bpf_prog_run include/linux/filter.h:725 [inline] bpf_prog_run_array include/linux/bpf.h:2215 [inline] trace_call_bpf+0x36a/0x8a0 kernel/trace/bpf_trace.c:146 perf_trace_run_bpf_submit+0x82/0x180 kernel/events/core.c:10807 do_perf_trace_lock include/trace/events/lock.h:50 [inline] perf_trace_lock+0x39c/0x4a0 include/trace/events/lock.h:50 __do_trace_lock_release include/trace/events/lock.h:69 [inline] trace_lock_release include/trace/events/lock.h:69 [inline] lock_release+0x3b4/0x3e0 kernel/locking/lockdep.c:5877 __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:149 [inline] _raw_spin_unlock_irqrestore+0x7a/0x140 kernel/locking/spinlock.c:194 __bpf_ringbuf_reserve+0x4c5/0x650 kernel/bpf/ringbuf.c:461 ____bpf_ringbuf_output kernel/bpf/ringbuf.c:549 [inline] bpf_ringbuf_output+0x67/0x1e0 kernel/bpf/ringbuf.c:539 bpf_prog_918f90024333f9ff+0x43/0x47 bpf_dispatcher_nop_func include/linux/bpf.h:1316 [inline] __bpf_prog_run include/linux/filter.h:718 [inline] bpf_prog_run include/linux/filter.h:725 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2363 [inline] bpf_trace_run3+0x33c/0x5b0 kernel/trace/bpf_trace.c:2405 __bpf_trace_percpu_free_percpu+0x217/0x2f0 include/trace/events/percpu.h:54 __do_trace_percpu_free_percpu include/trace/events/percpu.h:54 [inline] trace_percpu_free_percpu+0x1a0/0x210 include/trace/events/percpu.h:54 free_percpu+0xb29/0x1160 mm/percpu.c:2264 mm_destroy_cid include/linux/mm_types.h:1363 [inline] __mmdrop+0x305/0x490 kernel/fork.c:946 exit_mm+0x221/0x310 kernel/exit.c:589 do_exit+0x994/0x27f0 kernel/exit.c:940 do_group_exit+0x207/0x2c0 kernel/exit.c:1102 __do_sys_exit_group kernel/exit.c:1113 [inline] __se_sys_exit_group kernel/exit.c:1111 [inline] __x64_sys_exit_group+0x3f/0x40 kernel/exit.c:1111 x64_sys_call+0x26c3/0x26d0 arch/x86/include/generated/asm/syscalls_64.h:232 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xf3/0x210 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f8a9f4fca90 Code: Unable to access opcode bytes at 0x7f8a9f4fca66. RSP: 002b:00007fff4eff2418 EFLAGS: 00000202 ORIG_RAX: 00000000000000e7 RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f8a9f4fca90 RDX: 00000000000000e7 RSI: 000000000000003c RDI: 0000000000000000 RBP: 0000000000000000 R08: 0000000000000007 R09: 6f7c79bd86dda6f9 R10: 00000000ffffffff R11: 0000000000000202 R12: 000055b7e25726c0 R13: 00007fff4eff2458 R14: 0000000000000001 R15: 000055b7e2554910