====================================================== WARNING: possible circular locking dependency detected 6.12.0-rc6-syzkaller-00169-g906bd684e4b1 #0 Not tainted ------------------------------------------------------ syz.5.1127/10600 is trying to acquire lock: ffff88806a929598 (krc.lock){..-.}-{2:2}, at: krc_this_cpu_lock kernel/rcu/tree.c:3312 [inline] ffff88806a929598 (krc.lock){..-.}-{2:2}, at: add_ptr_to_bulk_krc_lock kernel/rcu/tree.c:3725 [inline] ffff88806a929598 (krc.lock){..-.}-{2:2}, at: kvfree_call_rcu+0xda/0xbe0 kernel/rcu/tree.c:3811 but task is already holding lock: ffff88806a92a858 (&base->lock){-.-.}-{2:2}, at: lock_timer_base+0x5d/0x220 kernel/time/timer.c:1051 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (&base->lock){-.-.}-{2:2}: __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0x3a/0x60 kernel/locking/spinlock.c:162 lock_timer_base+0x5d/0x220 kernel/time/timer.c:1051 __mod_timer+0x426/0xdc0 kernel/time/timer.c:1132 add_timer_global+0x8a/0xc0 kernel/time/timer.c:1330 __queue_delayed_work+0x1ba/0x2e0 kernel/workqueue.c:2523 queue_delayed_work_on+0x12a/0x150 kernel/workqueue.c:2552 kvfree_call_rcu+0x749/0xbe0 kernel/rcu/tree.c:3839 pwq_release_workfn+0x4dd/0xa50 kernel/workqueue.c:5078 kthread_worker_fn+0x305/0xba0 kernel/kthread.c:844 kthread+0x2c1/0x3a0 kernel/kthread.c:389 ret_from_fork+0x45/0x80 arch/x86/kernel/process.c:147 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244 -> #0 (krc.lock){..-.}-{2:2}: check_prev_add kernel/locking/lockdep.c:3161 [inline] check_prevs_add kernel/locking/lockdep.c:3280 [inline] validate_chain kernel/locking/lockdep.c:3904 [inline] __lock_acquire+0x250b/0x3ce0 kernel/locking/lockdep.c:5202 lock_acquire.part.0+0x11b/0x380 kernel/locking/lockdep.c:5825 __raw_spin_lock include/linux/spinlock_api_smp.h:133 [inline] _raw_spin_lock+0x2e/0x40 kernel/locking/spinlock.c:154 krc_this_cpu_lock kernel/rcu/tree.c:3312 [inline] add_ptr_to_bulk_krc_lock kernel/rcu/tree.c:3725 [inline] kvfree_call_rcu+0xda/0xbe0 kernel/rcu/tree.c:3811 trie_delete_elem+0x5c5/0x820 kernel/bpf/lpm_trie.c:540 bpf_prog_2e5e7763945ac34e+0x45/0x49 bpf_dispatcher_nop_func include/linux/bpf.h:1265 [inline] __bpf_prog_run include/linux/filter.h:701 [inline] bpf_prog_run include/linux/filter.h:708 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2316 [inline] bpf_trace_run2+0x231/0x590 kernel/trace/bpf_trace.c:2357 __bpf_trace_timer_start+0xc7/0x100 include/trace/events/timer.h:52 __traceiter_timer_start+0x64/0xb0 include/trace/events/timer.h:52 trace_timer_start include/trace/events/timer.h:52 [inline] enqueue_timer+0x2b4/0x550 kernel/time/timer.c:663 internal_add_timer kernel/time/timer.c:688 [inline] __mod_timer+0x8d7/0xdc0 kernel/time/timer.c:1183 sk_reset_timer+0x21/0xc0 net/core/sock.c:3508 tipc_sk_finish_conn+0x183/0x790 net/tipc/socket.c:1671 tipc_socketpair+0x364/0x470 net/tipc/socket.c:3347 __sys_socketpair+0x2f0/0x5a0 net/socket.c:1796 __do_sys_socketpair net/socket.c:1832 [inline] __se_sys_socketpair net/socket.c:1829 [inline] __x64_sys_socketpair+0x96/0x100 net/socket.c:1829 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f other info that might help us debug this: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&base->lock); lock(krc.lock); lock(&base->lock); lock(krc.lock); *** DEADLOCK *** 2 locks held by syz.5.1127/10600: #0: ffff88806a92a858 (&base->lock){-.-.}-{2:2}, at: lock_timer_base+0x5d/0x220 kernel/time/timer.c:1051 #1: ffffffff8e1b8340 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:337 [inline] #1: ffffffff8e1b8340 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline] #1: ffffffff8e1b8340 (rcu_read_lock){....}-{1:2}, at: __bpf_trace_run kernel/trace/bpf_trace.c:2315 [inline] #1: ffffffff8e1b8340 (rcu_read_lock){....}-{1:2}, at: bpf_trace_run2+0x1c2/0x590 kernel/trace/bpf_trace.c:2357 stack backtrace: CPU: 3 UID: 0 PID: 10600 Comm: syz.5.1127 Not tainted 6.12.0-rc6-syzkaller-00169-g906bd684e4b1 #0 Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:120 print_circular_bug+0x41c/0x610 kernel/locking/lockdep.c:2074 check_noncircular+0x31a/0x400 kernel/locking/lockdep.c:2206 check_prev_add kernel/locking/lockdep.c:3161 [inline] check_prevs_add kernel/locking/lockdep.c:3280 [inline] validate_chain kernel/locking/lockdep.c:3904 [inline] __lock_acquire+0x250b/0x3ce0 kernel/locking/lockdep.c:5202 lock_acquire.part.0+0x11b/0x380 kernel/locking/lockdep.c:5825 __raw_spin_lock include/linux/spinlock_api_smp.h:133 [inline] _raw_spin_lock+0x2e/0x40 kernel/locking/spinlock.c:154 krc_this_cpu_lock kernel/rcu/tree.c:3312 [inline] add_ptr_to_bulk_krc_lock kernel/rcu/tree.c:3725 [inline] kvfree_call_rcu+0xda/0xbe0 kernel/rcu/tree.c:3811 trie_delete_elem+0x5c5/0x820 kernel/bpf/lpm_trie.c:540 bpf_prog_2e5e7763945ac34e+0x45/0x49 bpf_dispatcher_nop_func include/linux/bpf.h:1265 [inline] __bpf_prog_run include/linux/filter.h:701 [inline] bpf_prog_run include/linux/filter.h:708 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2316 [inline] bpf_trace_run2+0x231/0x590 kernel/trace/bpf_trace.c:2357 __bpf_trace_timer_start+0xc7/0x100 include/trace/events/timer.h:52 __traceiter_timer_start+0x64/0xb0 include/trace/events/timer.h:52 trace_timer_start include/trace/events/timer.h:52 [inline] enqueue_timer+0x2b4/0x550 kernel/time/timer.c:663 internal_add_timer kernel/time/timer.c:688 [inline] __mod_timer+0x8d7/0xdc0 kernel/time/timer.c:1183 sk_reset_timer+0x21/0xc0 net/core/sock.c:3508 tipc_sk_finish_conn+0x183/0x790 net/tipc/socket.c:1671 tipc_socketpair+0x364/0x470 net/tipc/socket.c:3347 __sys_socketpair+0x2f0/0x5a0 net/socket.c:1796 __do_sys_socketpair net/socket.c:1832 [inline] __se_sys_socketpair net/socket.c:1829 [inline] __x64_sys_socketpair+0x96/0x100 net/socket.c:1829 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7ff2b797e719 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007ff2b86d3038 EFLAGS: 00000246 ORIG_RAX: 0000000000000035 RAX: ffffffffffffffda RBX: 00007ff2b7b35f80 RCX: 00007ff2b797e719 RDX: 0000000000000000 RSI: 0000000000000005 RDI: 000000000000001e RBP: 00007ff2b79f139e R08: 0000000000000000 R09: 0000000000000000 R10: 0000000020000940 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 00007ff2b7b35f80 R15: 00007ffebc2e6308