syzbot


WARNING in stashed_dentry_prune

Status: fixed on 2024/04/11 08:41
Subsystems: fs
[Documentation on labels]
Reported-by: syzbot+9b5ec5ccf7234cc6cb86@syzkaller.appspotmail.com
Fix commit: 9d9539db8638 pidfs: remove config option
First crash: 73d, last: 73d
Cause bisection: introduced by (bisect log) :
commit 2558e3b23112adb82a558bab616890a790a38bc6
Author: Christian Brauner <brauner@kernel.org>
Date: Wed Feb 21 08:59:51 2024 +0000

  libfs: add stashed_dentry_prune()

Crash: WARNING in stashed_dentry_prune (log)
Repro: C syz .config
  
Discussions (2)
Title Replies (including bot) Last reply
[PATCH] libfs: fix warning in stashed_dentry_prune 2 (2) 2024/03/14 11:02
[syzbot] [fs?] WARNING in stashed_dentry_prune 3 (7) 2024/03/14 10:57
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream WARNING in stashed_dentry_prune (2) fs C done 54 28d 37d 26/26 fixed on 2024/05/18 18:27
Last patch testing requests (3)
Created Duration User Patch Repo Result
2024/03/14 10:57 1h21m brauner@kernel.org https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 9d9539db8638cfe053fcd1f441746f0e2c8c2d32 OK log
2024/03/13 12:42 24m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master OK log
2024/03/13 12:30 23m eadavis@qq.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master OK log

Sample crash report:
WARNING: CPU: 0 PID: 5112 at fs/libfs.c:2117 stashed_dentry_prune+0x97/0xa0 fs/libfs.c:2117
Modules linked in:
CPU: 0 PID: 5112 Comm: syz-executor244 Not tainted 6.8.0-syzkaller-00295-g0f1a876682f0 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/29/2024
RIP: 0010:stashed_dentry_prune+0x97/0xa0 fs/libfs.c:2117
Code: 00 00 e8 3c cc e2 ff 31 c9 4c 89 f0 f0 49 0f b1 0f eb 05 e8 cb ac 80 ff 5b 41 5c 41 5e 41 5f c3 cc cc cc cc e8 ba ac 80 ff 90 <0f> 0b 90 eb e9 0f 1f 40 00 90 90 90 90 90 90 90 90 90 90 90 90 90
RSP: 0018:ffffc90003a97b88 EFLAGS: 00010293

RAX: ffffffff8212ba76 RBX: ffff88807e1bbe58 RCX: ffff8880786a0000
RDX: 0000000000000000 RSI: 0000000000000010 RDI: ffff88807e1bbd60
RBP: 0000000000000001 R08: ffffffff820ce514 R09: 1ffff1100fc377bf
R10: dffffc0000000000 R11: ffffffff8212b9e0 R12: dffffc0000000000
R13: dffffc0000000000 R14: ffff88807e1bbd60 R15: 0000000000000000
FS:  00007fbd2c2fc6c0(0000) GS:ffff8880b9400000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fbd2c2dbd58 CR3: 0000000075822000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 __dentry_kill+0xa9/0x630 fs/dcache.c:594
 dput+0x19f/0x2b0 fs/dcache.c:845
 prepare_anon_dentry fs/libfs.c:2018 [inline]
 path_from_stashed+0x695/0xb00 fs/libfs.c:2094
 pidfs_alloc_file+0x136/0x210 fs/pidfs.c:248
 __pidfd_prepare kernel/fork.c:2027 [inline]
 pidfd_prepare+0x7c/0x130 kernel/fork.c:2075
 pidfd_create kernel/pid.c:614 [inline]
 __do_sys_pidfd_open kernel/pid.c:650 [inline]
 __se_sys_pidfd_open+0xe4/0x280 kernel/pid.c:635
 do_syscall_64+0xf9/0x240
 entry_SYSCALL_64_after_hwframe+0x6f/0x77
RIP: 0033:0x7fbd2c35c7d9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 51 18 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:00007fbd2c2fc208 EFLAGS: 00000246 ORIG_RAX: 00000000000001b2
RAX: ffffffffffffffda RBX: 00007fbd2c3e63d8 RCX: 00007fbd2c35c7d9
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 00000000000013f0
RBP: 00007fbd2c3e63d0 R08: 00007fbd2c2fbfa7 R09: 0000000000000032
R10: 0000000000000000 R11: 0000000000000246 R12: 00007fbd2c3b317c
R13: 00007fbd2c2fc210 R14: 0000000000000001 R15: 00007fbd2c3b301d
 </TASK>

Crashes (20):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/03/12 02:18 upstream 0f1a876682f0 6ee49f2e .config strace log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce WARNING in stashed_dentry_prune
2024/03/12 11:37 upstream 855684c7d938 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce WARNING in stashed_dentry_prune
2024/03/12 11:15 upstream 045395d86acd 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root WARNING in stashed_dentry_prune
2024/03/12 10:30 upstream 045395d86acd 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root WARNING in stashed_dentry_prune
2024/03/12 09:38 upstream 045395d86acd 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root WARNING in stashed_dentry_prune
2024/03/12 07:15 upstream 8ede842f669b 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-selinux-root WARNING in stashed_dentry_prune
2024/03/12 06:34 upstream 86833aec4479 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs WARNING in stashed_dentry_prune
2024/03/12 06:34 upstream 045395d86acd 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root WARNING in stashed_dentry_prune
2024/03/12 06:33 upstream 045395d86acd 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root WARNING in stashed_dentry_prune
2024/03/12 06:21 upstream 86833aec4479 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs WARNING in stashed_dentry_prune
2024/03/12 05:48 upstream 045395d86acd 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root WARNING in stashed_dentry_prune
2024/03/12 04:16 upstream 86833aec4479 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs WARNING in stashed_dentry_prune
2024/03/12 03:24 upstream 86833aec4479 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs WARNING in stashed_dentry_prune
2024/03/12 02:49 upstream 045395d86acd 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root WARNING in stashed_dentry_prune
2024/03/12 02:28 upstream 045395d86acd 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root WARNING in stashed_dentry_prune
2024/03/12 02:21 upstream 86833aec4479 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs WARNING in stashed_dentry_prune
2024/03/12 00:55 upstream 0f1a876682f0 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce WARNING in stashed_dentry_prune
2024/03/12 02:34 upstream 0f1a876682f0 6ee49f2e .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream WARNING in stashed_dentry_prune
2024/03/12 06:18 upstream 8ede842f669b 6ee49f2e .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream-386 WARNING in stashed_dentry_prune
2024/03/12 04:52 upstream 8ede842f669b 6ee49f2e .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream-386 WARNING in stashed_dentry_prune
* Struck through repros no longer work on HEAD.