------------[ cut here ]------------
refcount_t: addition on 0; use-after-free.
WARNING: CPU: 1 PID: 12 at lib/refcount.c:25 refcount_warn_saturate+0xf3/0x1b0 lib/refcount.c:25
Modules linked in:
CPU: 1 PID: 12 Comm: kworker/u4:1 Not tainted 6.6.93-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
Workqueue: bat_events batadv_nc_worker
RIP: 0010:refcount_warn_saturate+0xf3/0x1b0 lib/refcount.c:25
Code: 15 0a 01 0f 85 98 00 00 00 e8 39 41 66 fd 5b 41 5e c3 e8 30 41 66 fd c6 05 e1 00 15 0a 01 48 c7 c7 40 0f fc 8a e8 0d a5 30 fd <0f> 0b eb e0 e8 14 41 66 fd c6 05 c6 00 15 0a 01 48 c7 c7 a0 0f fc
RSP: 0018:ffffc900001f0848 EFLAGS: 00010246
RAX: 70da8a52998d5e00 RBX: 0000000000000002 RCX: ffff88801ba55a00
RDX: 0000000000000100 RSI: 0000000000000000 RDI: 0000000000000002
RBP: ffffc900001f09d0 R08: ffffc900001f0447 R09: 1ffff9200003e088
R10: dffffc0000000000 R11: fffff5200003e089 R12: ffff888028290000
R13: dffffc0000000000 R14: ffff888028290154 R15: ffff888030727400
FS: 0000000000000000(0000) GS:ffff8880b8f00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000200000022000 CR3: 000000002deb2000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
__refcount_add include/linux/refcount.h:-1 [inline]
__refcount_inc include/linux/refcount.h:250 [inline]
refcount_inc include/linux/refcount.h:267 [inline]
get_net include/net/net_namespace.h:261 [inline]
tipc_aead_encrypt net/tipc/crypto.c:821 [inline]
tipc_crypto_xmit+0x17cf/0x2250 net/tipc/crypto.c:1761
tipc_bearer_xmit_skb+0x246/0x3f0 net/tipc/bearer.c:572
tipc_disc_timeout+0x581/0x6d0 net/tipc/discover.c:338
call_timer_fn+0x16e/0x530 kernel/time/timer.c:1700
expire_timers kernel/time/timer.c:1751 [inline]
__run_timers+0x52d/0x7d0 kernel/time/timer.c:2022
run_timer_softirq+0x67/0xf0 kernel/time/timer.c:2035
handle_softirqs+0x280/0x820 kernel/softirq.c:578
__do_softirq kernel/softirq.c:612 [inline]
invoke_softirq kernel/softirq.c:452 [inline]
__irq_exit_rcu+0xc7/0x190 kernel/softirq.c:661
irq_exit_rcu+0x9/0x20 kernel/softirq.c:673
instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1088 [inline]
sysvec_apic_timer_interrupt+0xa4/0xc0 arch/x86/kernel/apic/apic.c:1088
asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:687
RIP: 0010:finish_task_switch+0x26a/0x920 kernel/sched/core.c:5255
Code: 0f 84 37 01 00 00 48 85 db 0f 85 56 01 00 00 e9 f6 04 00 00 4c 8b 75 d0 4c 89 e7 e8 90 6d 13 09 e8 0b b5 2f 00 fb 4c 8b 65 c0 <49> 8d bc 24 f8 15 00 00 48 89 f8 48 c1 e8 03 42 0f b6 04 28 84 c0
RSP: 0018:ffffc90000117758 EFLAGS: 00000282
RAX: 70da8a52998d5e00 RBX: 0000000000000000 RCX: 70da8a52998d5e00
RDX: dffffc0000000000 RSI: ffffffff8aaab2c0 RDI: ffffffff8afc6780
RBP: ffffc900001177b0 R08: ffffffff90d845ff R09: 1ffffffff21b08bf
R10: dffffc0000000000 R11: fffffbfff21b08c0 R12: ffff88801ba55a00
R13: dffffc0000000000 R14: ffff888023403c00 R15: ffff8880b8f3cf08
context_switch kernel/sched/core.c:5384 [inline]
__schedule+0x14ea/0x4580 kernel/sched/core.c:6700
preempt_schedule_irq+0xb5/0x140 kernel/sched/core.c:7010
irqentry_exit+0x67/0x70 kernel/entry/common.c:438
asm_sysvec_reschedule_ipi+0x1a/0x20 arch/x86/include/asm/idtentry.h:692
RIP: 0010:__preempt_count_add arch/x86/include/asm/preempt.h:80 [inline]
RIP: 0010:rcu_is_watching+0x6/0xb0 kernel/rcu/tree.c:699
Code: eb 99 e8 5d 86 f6 08 48 c7 c7 c0 65 d3 8c 4c 89 f6 e8 5e 8f e2 02 e9 53 ff ff ff 66 0f 1f 84 00 00 00 00 00 f3 0f 1e fa 41 57 <41> 56 53 65 ff 05 e8 29 94 7e e8 3b 9c f6 08 89 c3 83 f8 08 73 60
RSP: 0018:ffffc90000117b50 EFLAGS: 00000202
RAX: ffffffff8a2e67ef RBX: 0000000000000001 RCX: 0000000000000000
RDX: ffff88801ba55a00 RSI: 0000000000000001 RDI: 0000000000000000
RBP: fffffffffffffe38 R08: dffffc0000000000 R09: 1ffffffff21b08a4
R10: dffffc0000000000 R11: fffffbfff21b08a5 R12: dffffc0000000000
R13: ffffffff8a2e66c2 R14: ffff88807cd84c80 R15: 0000000000000167
rcu_read_unlock include/linux/rcupdate.h:815 [inline]
batadv_nc_purge_orig_hash net/batman-adv/network-coding.c:412 [inline]
batadv_nc_worker+0x208/0x610 net/batman-adv/network-coding.c:719
process_one_work kernel/workqueue.c:2634 [inline]
process_scheduled_works+0xa45/0x15b0 kernel/workqueue.c:2711
worker_thread+0xa55/0xfc0 kernel/workqueue.c:2792
kthread+0x2fa/0x390 kernel/kthread.c:388
ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152
ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293
----------------
Code disassembly (best guess):
0: 0f 84 37 01 00 00 je 0x13d
6: 48 85 db test %rbx,%rbx
9: 0f 85 56 01 00 00 jne 0x165
f: e9 f6 04 00 00 jmp 0x50a
14: 4c 8b 75 d0 mov -0x30(%rbp),%r14
18: 4c 89 e7 mov %r12,%rdi
1b: e8 90 6d 13 09 call 0x9136db0
20: e8 0b b5 2f 00 call 0x2fb530
25: fb sti
26: 4c 8b 65 c0 mov -0x40(%rbp),%r12
* 2a: 49 8d bc 24 f8 15 00 lea 0x15f8(%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