syzbot


WARNING: refcount bug in ax25_release

Status: upstream: reported on 2024/06/15 15:04
Reported-by: syzbot+7ed59d42e7f489c36a83@syzkaller.appspotmail.com
First crash: 4d04h, last: 4d04h
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream WARNING: refcount bug in ax25_release (3) hams 39 6h18m 23d 0/27 upstream: reported on 2024/05/26 23:38
upstream WARNING: refcount bug in ax25_release hams 1 281d 281d 0/27 closed as invalid on 2023/12/15 13:48
upstream WARNING: refcount bug in ax25_release (2) hams C 240 27d 93d 26/27 fixed on 2024/05/22 23:16

Sample crash report:
------------[ 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>

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/06/15 15:03 linux-6.1.y ae9f2a70d69e f429ab00 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan WARNING: refcount bug in ax25_release
2024/06/15 15:03 linux-6.1.y ae9f2a70d69e f429ab00 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan WARNING: refcount bug in ax25_release
* Struck through repros no longer work on HEAD.