Re: [syzbot] WARNING in mntput_no_expire (3)

syzbot
2022-05-15T07:58:36Z

WARNING in mnt_check_count

------------[ cut here ]------------
WARNING: CPU: 0 PID: 4324 at fs/namespace.c:1307 mnt_check_count fs/namespace.c:1307 [inline]
WARNING: CPU: 0 PID: 4324 at fs/namespace.c:1307 mnt_check_count+0x14a/0x210 fs/namespace.c:1301
Modules linked in:
CPU: 1 PID: 4324 Comm: syz-executor.0 Not tainted 5.18.0-rc6-syzkaller-00009-gfeb9c5e19e91-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:mnt_check_count fs/namespace.c:1307 [inline]
RIP: 0010:mnt_check_count+0x14a/0x210 fs/namespace.c:1301
Code: ff 89 de bf 01 00 00 00 e8 c3 ed 9d ff 83 fb 01 7e 1a 48 83 c4 18 5b 5d 41 5c 41 5d 41 5e 41 5f e9 8b eb 9d ff e8 86 eb 9d ff <0f> 0b e8 7f eb 9d ff 49 8d be c8 00 00 00 48 b8 00 00 00 00 00 fc
RSP: 0018:ffffc90003adfe60 EFLAGS: 00010293
RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000
RDX: ffff88801613bb00 RSI: ffffffff81db555a RDI: 0000000000000003
RBP: 0000000000000008 R08: 0000000000000000 R09: 0000000000000001
R10: ffffffff81db5528 R11: 0000000000000000 R12: 0000000000000002
R13: dffffc0000000000 R14: ffff88814013cda0 R15: ffffed10280279ba
FS: 000055555725a400(0000) GS:ffff8880b9d00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fb39859d090 CR3: 000000001a0ad000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
fput_many.part.0+0x3d/0x1a0 fs/file_table.c:375
fput_many fs/file_table.c:396 [inline]
fput+0x42/0x50 fs/file_table.c:395
filp_close+0x124/0x160 fs/open.c:1329
close_fd+0x6f/0xa0 fs/file.c:671
__do_sys_close fs/open.c:1342 [inline]
__se_sys_close fs/open.c:1340 [inline]
__x64_sys_close+0x2f/0xa0 fs/open.c:1340
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x44/0xae
RIP: 0033:0x7f4ef943bd2b
Code: 0f 05 48 3d 00 f0 ff ff 77 45 c3 0f 1f 40 00 48 83 ec 18 89 7c 24 0c e8 63 fc ff ff 8b 7c 24 0c 41 89 c0 b8 03 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 35 44 89 c7 89 44 24 0c e8 a1 fc ff ff 8b 44
RSP: 002b:00007ffc2b1ebbc0 EFLAGS: 00000293
ORIG_RAX: 0000000000000003
RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 00007f4ef943bd2b
RDX: 0000001b31d20000 RSI: 0000000000000000 RDI: 0000000000000003
RBP: 00007f4ef959d960 R08: 0000000000000000 R09: 00007ffc2b1fa080
R10: 00007ffc2b1fa090 R11: 0000000000000293 R12: 0000000000015538
R13: 00007ffc2b1ebcc0 R14: 00007ffc2b1ebce0 R15: 0000000000000032
</TASK>

Tested on:

commit: feb9c5e1 Merge tag 'for_linus' of git://git.kernel.org..
git tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
console output: https://syzkaller.appspot.com/x/log.txt?x=1488f396f00000
kernel config: https://syzkaller.appspot.com/x/.config?x=79caa0035f59d385
dashboard link: https://syzkaller.appspot.com/bug?extid=5b1e53987f858500ec00
compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2
patch: https://syzkaller.appspot.com/x/patch.diff?x=12375f31f00000