syzbot


WARNING: refcount bug in p9_req_put (2)

Status: auto-obsoleted due to no activity on 2023/12/09 05:29
Subsystems: v9fs
[Documentation on labels]
Reported-by: syzbot+3ba8f2097df93bc26d2f@syzkaller.appspotmail.com
First crash: 553d, last: 200d
Discussions (4)
Title Replies (including bot) Last reply
[syzbot] Monthly v9fs report (Sep 2023) 0 (1) 2023/09/11 08:39
[syzbot] Monthly v9fs report (Aug 2023) 0 (1) 2023/08/09 12:33
[syzbot] Monthly 9p report (May 2023) 0 (1) 2023/05/07 06:35
[syzbot] WARNING: refcount bug in p9_req_put (2) 0 (1) 2022/09/19 04:54
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 WARNING: refcount bug in p9_req_put 2 1600d 1641d 0/1 auto-closed as invalid on 2020/02/28 21:29
upstream WARNING: refcount bug in p9_req_put (3) v9fs 3 16d 52d 0/26 upstream: reported on 2024/01/26 09:05
upstream WARNING: refcount bug in p9_req_put v9fs syz inconclusive done 6 1397d 1950d 15/26 fixed on 2020/11/16 12:12

Sample crash report:
------------[ cut here ]------------
refcount_t: underflow; use-after-free.
WARNING: CPU: 0 PID: 28704 at lib/refcount.c:28 refcount_warn_saturate+0x140/0x1f0 lib/refcount.c:28
Modules linked in:
CPU: 0 PID: 28704 Comm: syz-executor.3 Not tainted 6.5.0-syzkaller-08262-gef2a0b7cdbc5 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:refcount_warn_saturate+0x140/0x1f0 lib/refcount.c:28
Code: 0a 31 ff 89 de e8 90 73 64 fd 84 db 0f 85 6e ff ff ff e8 53 78 64 fd 48 c7 c7 a0 8d c8 8a c6 05 7c a7 74 0a 01 e8 b0 c2 2a fd <0f> 0b e9 4f ff ff ff e8 34 78 64 fd 0f b6 1d 62 a7 74 0a 31 ff 89
RSP: 0018:ffffc9000391fab0 EFLAGS: 00010286
RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffc9000ce33000
RDX: 0000000000040000 RSI: ffffffff814d8ca6 RDI: 0000000000000001
RBP: ffff888078425558 R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000000 R11: 000000000000cd98 R12: ffff888078425550
R13: ffff888078425558 R14: ffff888077234c00 R15: 00000000fffffe00
FS:  00007f64be9c86c0(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000001b32236000 CR3: 0000000076cbc000 CR4: 0000000000350ef0
Call Trace:
 <TASK>
 __refcount_sub_and_test include/linux/refcount.h:283 [inline]
 __refcount_dec_and_test include/linux/refcount.h:315 [inline]
 refcount_dec_and_test include/linux/refcount.h:333 [inline]
 p9_req_put+0x1f0/0x250 net/9p/client.c:401
 p9_client_rpc+0x58e/0xc10 net/9p/client.c:756
 p9_client_getattr_dotl+0xba/0x1d0 net/9p/client.c:1730
 v9fs_mount+0x8f3/0xcd0 fs/9p/vfs_super.c:158
 legacy_get_tree+0x109/0x220 fs/fs_context.c:638
 vfs_get_tree+0x8c/0x370 fs/super.c:1724
 do_new_mount fs/namespace.c:3335 [inline]
 path_mount+0x1492/0x1ed0 fs/namespace.c:3662
 do_mount fs/namespace.c:3675 [inline]
 __do_sys_mount fs/namespace.c:3884 [inline]
 __se_sys_mount fs/namespace.c:3861 [inline]
 __x64_sys_mount+0x293/0x310 fs/namespace.c:3861
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f64bdc7cae9
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:00007f64be9c80c8 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007f64bdd9c120 RCX: 00007f64bdc7cae9
RDX: 0000000020000140 RSI: 0000000020000200 RDI: 0000000000000000
RBP: 00007f64bdcc847a R08: 0000000020000580 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000006e R14: 00007f64bdd9c120 R15: 00007fff23ee8808
 </TASK>

Crashes (9):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/08/31 05:29 upstream ef2a0b7cdbc5 84803932 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root WARNING: refcount bug in p9_req_put
2022/11/03 11:02 upstream 200204f56f3b 7a2ebf95 .config console log report info ci-qemu-upstream WARNING: refcount bug in p9_req_put
2022/09/12 11:57 upstream 80e78fcce86d 356d8217 .config console log report info ci-qemu-upstream WARNING: refcount bug in p9_req_put
2023/04/24 15:17 upstream 457391b03803 c778c7f4 .config console log report info ci-qemu-upstream-386 WARNING: refcount bug in p9_req_put
2023/04/15 16:54 upstream 7a934f4bd7d6 ec410564 .config console log report info ci-qemu-upstream-386 WARNING: refcount bug in p9_req_put
2023/01/01 22:50 upstream 150aae354b81 ab32d508 .config console log report info ci-qemu-upstream-386 WARNING: refcount bug in p9_req_put
2022/11/19 10:48 upstream fe24a97cf254 5bb70014 .config console log report info ci-qemu-upstream-386 WARNING: refcount bug in p9_req_put
2022/10/26 20:03 upstream 98555239e4c3 86777b7f .config console log report info ci-qemu-upstream-386 WARNING: refcount bug in p9_req_put
2023/08/07 11:13 linux-next f7dc24b34138 0ef3dfda .config console log report info ci-upstream-linux-next-kasan-gce-root WARNING: refcount bug in p9_req_put
* Struck through repros no longer work on HEAD.