[v6.1] WARNING: refcount bug in ax25_release

5 views
Skip to first unread message

syzbot

unread,
Jun 15, 2024, 11:04:21 AM6/15/24
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: ae9f2a70d69e Linux 6.1.93
git tree: linux-6.1.y
console output: https://syzkaller.appspot.com/x/log.txt?x=17146851980000
kernel config: https://syzkaller.appspot.com/x/.config?x=1d7ac9fef66f54aa
dashboard link: https://syzkaller.appspot.com/bug?extid=7ed59d42e7f489c36a83
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/b6a79d8f90ec/disk-ae9f2a70.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/f1b3e75b81f1/vmlinux-ae9f2a70.xz
kernel image: https://storage.googleapis.com/syzbot-assets/80fc2213e3e5/bzImage-ae9f2a70.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+7ed59d...@syzkaller.appspotmail.com

------------[ cut here ]------------
refcount_t: decrement hit 0; leaking memory.
WARNING: CPU: 0 PID: 16004 at lib/refcount.c:31 refcount_warn_saturate+0x16d/0x1a0 lib/refcount.c:31
Modules linked in:
CPU: 0 PID: 16004 Comm: syz-executor.1 Not tainted 6.1.93-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/07/2024
RIP: 0010:refcount_warn_saturate+0x16d/0x1a0 lib/refcount.c:31
Code: c7 c7 00 09 3d 8b e8 e2 39 1a fd 0f 0b e9 6e ff ff ff e8 96 3c 52 fd c6 05 31 42 27 0a 01 48 c7 c7 60 09 3d 8b e8 c3 39 1a fd <0f> 0b e9 4f ff ff ff 89 d9 80 e1 07 80 c1 03 38 c1 0f 8c b2 fe ff
RSP: 0018:ffffc9000399fb48 EFLAGS: 00010246
RAX: de4416b10cf8aa00 RBX: 0000000000000004 RCX: ffff88801f788000
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: 0000000000000004 R08: ffffffff815292de R09: fffff52000733ec9
R10: 0000000000000000 R11: dffffc0000000001 R12: ffff88807ac6e5b8
R13: 0000000000000000 R14: ffff88807ac6e5fc R15: dffffc0000000000
FS: 00005555572f0480(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f5f245f6000 CR3: 0000000022e7c000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
__refcount_dec include/linux/refcount.h:344 [inline]
refcount_dec include/linux/refcount.h:359 [inline]
ref_tracker_free+0x6a0/0x7d0 lib/ref_tracker.c:118
netdev_tracker_free include/linux/netdevice.h:4028 [inline]
netdev_put include/linux/netdevice.h:4045 [inline]
ax25_release+0x3ef/0x940 net/ax25/af_ax25.c:1069
__sock_release net/socket.c:654 [inline]
sock_close+0xcd/0x230 net/socket.c:1400
__fput+0x3b7/0x890 fs/file_table.c:320
task_work_run+0x246/0x300 kernel/task_work.c:179
resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
exit_to_user_mode_loop+0xde/0x100 kernel/entry/common.c:177
exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:210
__syscall_exit_to_user_mode_work kernel/entry/common.c:292 [inline]
syscall_exit_to_user_mode+0x60/0x270 kernel/entry/common.c:303
do_syscall_64+0x47/0xb0 arch/x86/entry/common.c:87
entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f85b367cea9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 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 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fffca625378 EFLAGS: 00000246 ORIG_RAX: 00000000000001b4
RAX: 0000000000000000 RBX: 00000000000cfd37 RCX: 00007f85b367cea9
RDX: 0000000000000000 RSI: 000000000000001e RDI: 0000000000000003
RBP: ffffffffffffffff R08: 0000000000000001 R09: 0000000300000000
R10: 00007f85b3600000 R11: 0000000000000246 R12: 00007f85b37b3f80
R13: 00007f85b37b3f8c R14: 0000000000000032 R15: 00007f85b37b5980
</TASK>


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup

syzbot

unread,
Jan 7, 2025, 5:21:22 AM1/7/25
to syzkaller...@googlegroups.com
syzbot has found a reproducer for the following issue on:

HEAD commit: 7dc732d24ff7 Linux 6.1.123
git tree: linux-6.1.y
console output: https://syzkaller.appspot.com/x/log.txt?x=161555c4580000
kernel config: https://syzkaller.appspot.com/x/.config?x=da1827eaa51b65c3
dashboard link: https://syzkaller.appspot.com/bug?extid=7ed59d42e7f489c36a83
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
userspace arch: arm64
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1115a4b0580000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=158b1c18580000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/b77a36eba7b4/disk-7dc732d2.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/f5334562da28/vmlinux-7dc732d2.xz
kernel image: https://storage.googleapis.com/syzbot-assets/f0a16f9a500c/Image-7dc732d2.gz.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+7ed59d...@syzkaller.appspotmail.com

IPv6: ADDRCONF(NETDEV_CHANGE): bpq0: link becomes ready
------------[ cut here ]------------
refcount_t: decrement hit 0; leaking memory.
WARNING: CPU: 0 PID: 4301 at lib/refcount.c:31 refcount_warn_saturate+0x1e8/0x20c lib/refcount.c:31
Modules linked in:
CPU: 0 PID: 4301 Comm: syz-executor262 Not tainted 6.1.123-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
pstate: 60400005 (nZCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : refcount_warn_saturate+0x1e8/0x20c lib/refcount.c:31
lr : refcount_warn_saturate+0x1e8/0x20c lib/refcount.c:31
sp : ffff800021147750
x29: ffff800021147750 x28: dfff800000000000 x27: ffff0000d07a0080
x26: dfff800000000000 x25: ffff700004228ef4 x24: ffff0000c3e1c010
x23: ffff0000db7bf000 x22: ffff8000211477c0 x21: 0000000000000004
x20: ffff0000df2dc5fc x19: ffff80001840d000 x18: ffff800021146b40
x17: 0000000000000000 x16: ffff80001232d384 x15: 0000000000000000
x14: 00000000ffffffff x13: 0000000000000001 x12: 0000000000000001
x11: 0000000000ff0100 x10: 0000000000000000 x9 : d73fa8e2f867fb00
x8 : d73fa8e2f867fb00 x7 : 0000000000000001 x6 : 0000000000000001
x5 : ffff800021147038 x4 : ffff800015b731c0 x3 : ffff8000085869b0
x2 : 0000000000000001 x1 : 0000000100000000 x0 : 0000000000000000
Call trace:
refcount_warn_saturate+0x1e8/0x20c lib/refcount.c:31
__refcount_dec include/linux/refcount.h:344 [inline]
refcount_dec include/linux/refcount.h:359 [inline]
ref_tracker_free+0x550/0x6ac lib/ref_tracker.c:118
netdev_tracker_free include/linux/netdevice.h:4063 [inline]
netdev_put include/linux/netdevice.h:4080 [inline]
ax25_release+0x350/0x8ac net/ax25/af_ax25.c:1069
__sock_release net/socket.c:654 [inline]
sock_close+0xb8/0x1fc net/socket.c:1400
__fput+0x1c8/0x7c8 fs/file_table.c:320
____fput+0x20/0x30 fs/file_table.c:348
task_work_run+0x240/0x2f0 kernel/task_work.c:203
resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
do_notify_resume+0x2080/0x2cb8 arch/arm64/kernel/signal.c:1132
prepare_exit_to_user_mode arch/arm64/kernel/entry-common.c:137 [inline]
exit_to_user_mode arch/arm64/kernel/entry-common.c:142 [inline]
el0_svc+0x9c/0x168 arch/arm64/kernel/entry-common.c:638
el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655
el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:585
irq event stamp: 1876
hardirqs last enabled at (1875): [<ffff80000833f25c>] __up_console_sem+0xb4/0x100 kernel/printk/printk.c:261
hardirqs last disabled at (1876): [<ffff800012329064>] el1_dbg+0x24/0x80 arch/arm64/kernel/entry-common.c:405
softirqs last enabled at (1832): [<ffff8000114a6a48>] spin_unlock_bh include/linux/spinlock.h:396 [inline]
softirqs last enabled at (1832): [<ffff8000114a6a48>] ax25_cb_del+0x14c/0x198 net/ax25/af_ax25.c:70
softirqs last disabled at (1830): [<ffff8000114a692c>] spin_lock_bh include/linux/spinlock.h:356 [inline]
softirqs last disabled at (1830): [<ffff8000114a692c>] ax25_cb_del+0x30/0x198 net/ax25/af_ax25.c:65
---[ end trace 0000000000000000 ]---


---
If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.

syzbot

unread,
Jun 25, 2026, 9:06:21 AM (20 hours ago) Jun 25
to syzkaller...@googlegroups.com
Auto-closing this bug as obsolete.
No recent activity, existing reproducers are no longer triggering the issue.
Reply all
Reply to author
Forward
0 new messages