============================================ WARNING: possible recursive locking detected syzkaller #0 Not tainted -------------------------------------------- udevd/5233 is trying to acquire lock: ffffc9000d8910d8 (&rb->spinlock){-.-.}-{2:2}, at: __bpf_ringbuf_reserve+0x1c7/0x5a0 kernel/bpf/ringbuf.c:423 but task is already holding lock: ffffc9000d8230d8 (&rb->spinlock){-.-.}-{2:2}, at: __bpf_ringbuf_reserve+0x1c7/0x5a0 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/5233: #0: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:331 [inline] #0: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:841 [inline] #0: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: class_rcu_constructor include/linux/rcupdate.h:1155 [inline] #0: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: unwind_next_frame+0xa5/0x2390 arch/x86/kernel/unwind_orc.c:479 #1: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:331 [inline] #1: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:841 [inline] #1: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: __bpf_trace_run kernel/trace/bpf_trace.c:2256 [inline] #1: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: bpf_trace_run2+0x186/0x4b0 kernel/trace/bpf_trace.c:2298 #2: ffffc9000d8230d8 (&rb->spinlock){-.-.}-{2:2}, at: __bpf_ringbuf_reserve+0x1c7/0x5a0 kernel/bpf/ringbuf.c:423 #3: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:331 [inline] #3: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:841 [inline] #3: ffffffff8e139ea0 (rcu_read_lock){....}-{1:3}, at: trace_call_bpf+0xb7/0x850 kernel/trace/bpf_trace.c:-1 stack backtrace: CPU: 0 UID: 0 PID: 5233 Comm: udevd Not tainted syzkaller #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_deadlock_bug+0x28b/0x2a0 kernel/locking/lockdep.c:3041 check_deadlock kernel/locking/lockdep.c:3093 [inline] validate_chain+0x1a3f/0x2140 kernel/locking/lockdep.c:3895 __lock_acquire+0xab9/0xd20 kernel/locking/lockdep.c:5237 lock_acquire+0x120/0x360 kernel/locking/lockdep.c:5868 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xa7/0xf0 kernel/locking/spinlock.c:162 __bpf_ringbuf_reserve+0x1c7/0x5a0 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_df2ea1bb7efca089+0x36/0x54 bpf_dispatcher_nop_func include/linux/bpf.h:1332 [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:2292 [inline] trace_call_bpf+0x326/0x850 kernel/trace/bpf_trace.c:146 perf_trace_run_bpf_submit+0x78/0x170 kernel/events/core.c:10911 do_perf_trace_contention_end include/trace/events/lock.h:122 [inline] perf_trace_contention_end+0x253/0x2f0 include/trace/events/lock.h:122 __do_trace_contention_end include/trace/events/lock.h:122 [inline] trace_contention_end+0x111/0x140 include/trace/events/lock.h:122 __pv_queued_spin_lock_slowpath+0x9f9/0xb60 kernel/locking/qspinlock.c:374 pv_queued_spin_lock_slowpath arch/x86/include/asm/paravirt.h:557 [inline] queued_spin_lock_slowpath+0x43/0x50 arch/x86/include/asm/qspinlock.h:51 queued_spin_lock include/asm-generic/qspinlock.h:114 [inline] do_raw_spin_lock+0x21f/0x290 kernel/locking/spinlock_debug.c:116 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:111 [inline] _raw_spin_lock_irqsave+0xb3/0xf0 kernel/locking/spinlock.c:162 __bpf_ringbuf_reserve+0x1c7/0x5a0 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_6979e45824a16319+0x36/0x66 bpf_dispatcher_nop_func include/linux/bpf.h:1332 [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:2257 [inline] bpf_trace_run2+0x281/0x4b0 kernel/trace/bpf_trace.c:2298 __bpf_trace_tlb_flush+0xf5/0x150 include/trace/events/tlb.h:38 __traceiter_tlb_flush+0x76/0xd0 include/trace/events/tlb.h:38 __do_trace_tlb_flush include/trace/events/tlb.h:38 [inline] trace_tlb_flush+0x115/0x140 include/trace/events/tlb.h:38 flush_tlb_func+0x24e/0x6c0 arch/x86/mm/tlb.c:1133 csd_do_func kernel/smp.c:136 [inline] __flush_smp_call_function_queue+0x370/0xaa0 kernel/smp.c:546 __sysvec_call_function_single+0xa8/0x3d0 arch/x86/kernel/smp.c:271 instr_sysvec_call_function_single arch/x86/kernel/smp.c:266 [inline] sysvec_call_function_single+0x9e/0xc0 arch/x86/kernel/smp.c:266 asm_sysvec_call_function_single+0x1a/0x20 arch/x86/include/asm/idtentry.h:709 RIP: 0010:finish_task_switch+0x26b/0x950 kernel/sched/core.c:5225 Code: 0f 84 3c 01 00 00 48 85 db 0f 85 63 01 00 00 0f 1f 44 00 00 4c 8b 75 d0 4c 89 e7 e8 2f b7 ea 09 e8 5a 3f 36 00 fb 4c 8b 65 c0 <49> 8d bc 24 18 16 00 00 48 89 f8 48 c1 e8 03 42 0f b6 04 28 84 c0 RSP: 0018:ffffc900031d7498 EFLAGS: 00000282 RAX: c361178d2e361700 RBX: 0000000000000000 RCX: c361178d2e361700 RDX: 0000000000000000 RSI: ffffffff8d9b694e RDI: ffffffff8be33280 RBP: ffffc900031d74f0 R08: ffffffff8fa37f37 R09: 1ffffffff1f46fe6 R10: dffffc0000000000 R11: fffffbfff1f46fe7 R12: ffff88807cd69e00 R13: dffffc0000000000 R14: ffff888032773c00 R15: ffff8880b863ab58 context_switch kernel/sched/core.c:5360 [inline] __schedule+0x17a0/0x4cc0 kernel/sched/core.c:6961 preempt_schedule_irq+0xb5/0x150 kernel/sched/core.c:7288 irqentry_exit+0x6f/0x90 kernel/entry/common.c:197 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:702 RIP: 0010:lock_acquire+0x175/0x360 kernel/locking/lockdep.c:5872 Code: 00 00 00 00 9c 8f 44 24 30 f7 44 24 30 00 02 00 00 0f 85 cd 00 00 00 f7 44 24 08 00 02 00 00 74 01 fb 65 48 8b 05 4b e3 02 11 <48> 3b 44 24 58 0f 85 f2 00 00 00 48 83 c4 60 5b 41 5c 41 5d 41 5e RSP: 0018:ffffc900031d7898 EFLAGS: 00000206 RAX: c361178d2e361700 RBX: 0000000000000000 RCX: c361178d2e361700 RDX: 0000000000000001 RSI: ffffffff8dba5bfb RDI: ffffffff8be33280 RBP: ffffffff8172c195 R08: 0000000000000000 R09: ffffffff8172c195 R10: ffffc900031d7a58 R11: ffffffff81ac3930 R12: 0000000000000002 R13: ffffffff8e139ea0 R14: 0000000000000000 R15: 0000000000000246 rcu_lock_acquire include/linux/rcupdate.h:331 [inline] rcu_read_lock include/linux/rcupdate.h:841 [inline] class_rcu_constructor include/linux/rcupdate.h:1155 [inline] unwind_next_frame+0xc2/0x2390 arch/x86/kernel/unwind_orc.c:479 arch_stack_walk+0x11c/0x150 arch/x86/kernel/stacktrace.c:25 stack_trace_save+0x9c/0xe0 kernel/stacktrace.c:122 kasan_save_stack mm/kasan/common.c:47 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:68 kasan_save_free_info+0x46/0x50 mm/kasan/generic.c:576 poison_slab_object mm/kasan/common.c:243 [inline] __kasan_slab_free+0x5b/0x80 mm/kasan/common.c:275 kasan_slab_free include/linux/kasan.h:233 [inline] slab_free_hook mm/slub.c:2417 [inline] slab_free mm/slub.c:4680 [inline] kmem_cache_free+0x18f/0x400 mm/slub.c:4782 do_readlinkat+0x293/0x500 fs/stat.c:596 __do_sys_readlink fs/stat.c:613 [inline] __se_sys_readlink fs/stat.c:610 [inline] __x64_sys_readlink+0x7f/0x90 fs/stat.c:610 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0x3b0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fb5db7153a7 Code: 00 00 90 48 83 ec 10 48 63 ff 45 31 c9 45 31 c0 6a 00 31 c9 e8 8a 20 f9 ff 48 83 c4 18 c3 0f 1f 44 00 00 b8 59 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 8b 15 21 ba 0d 00 f7 d8 64 89 02 48 RSP: 002b:00007fff130fb6e8 EFLAGS: 00000246 ORIG_RAX: 0000000000000059 RAX: ffffffffffffffda RBX: 00007fff130fbbc0 RCX: 00007fb5db7153a7 RDX: 0000000000000400 RSI: 00007fff130fb6f0 RDI: 00007fff130fbbc0 RBP: 00007fff130fb6f0 R08: 0000000000000073 R09: 0000000000000001 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000400 R13: 0000000000000100 R14: 0000564e73f90be0 R15: 00007fff130fc650 ---------------- Code disassembly (best guess): 0: 0f 84 3c 01 00 00 je 0x142 6: 48 85 db test %rbx,%rbx 9: 0f 85 63 01 00 00 jne 0x172 f: 0f 1f 44 00 00 nopl 0x0(%rax,%rax,1) 14: 4c 8b 75 d0 mov -0x30(%rbp),%r14 18: 4c 89 e7 mov %r12,%rdi 1b: e8 2f b7 ea 09 call 0x9eab74f 20: e8 5a 3f 36 00 call 0x363f7f 25: fb sti 26: 4c 8b 65 c0 mov -0x40(%rbp),%r12 * 2a: 49 8d bc 24 18 16 00 lea 0x1618(%r12),%rdi <-- trapping instruction 31: 00 32: 48 89 f8 mov %rdi,%rax 35: 48 c1 e8 03 shr $0x3,%rax 39: 42 0f b6 04 28 movzbl (%rax,%r13,1),%eax 3e: 84 c0 test %al,%al