syzbot


INFO: task hung in vfs_rmdir

Status: auto-closed as invalid on 2022/09/21 08:53
Subsystems: fs
[Documentation on labels]
First crash: 644d, last: 644d

Sample crash report:
INFO: task syz-executor.3:7794 blocked for more than 143 seconds.
      Not tainted 5.19.0-rc3-syzkaller-00043-g3abc3ae553c7 #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor.3  state:D stack:29344 pid: 7794 ppid:  3646 flags:0x00000004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5146 [inline]
 __schedule+0xa00/0x4b50 kernel/sched/core.c:6458
 schedule+0xd2/0x1f0 kernel/sched/core.c:6530
 rwsem_down_write_slowpath+0x68a/0x11a0 kernel/locking/rwsem.c:1172
 __down_write_common kernel/locking/rwsem.c:1287 [inline]
 __down_write_common kernel/locking/rwsem.c:1284 [inline]
 __down_write kernel/locking/rwsem.c:1296 [inline]
 down_write+0x135/0x150 kernel/locking/rwsem.c:1543
 inode_lock include/linux/fs.h:741 [inline]
 vfs_rmdir.part.0+0x63/0x5a0 fs/namei.c:4050
 vfs_rmdir fs/namei.c:4046 [inline]
 do_rmdir+0x3a6/0x430 fs/namei.c:4122
 __do_sys_unlinkat fs/namei.c:4302 [inline]
 __se_sys_unlinkat fs/namei.c:4296 [inline]
 __x64_sys_unlinkat+0xeb/0x130 fs/namei.c:4296
 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+0x46/0xb0
RIP: 0033:0x7f8b46489109
RSP: 002b:00007f8b47598168 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007f8b4659c100 RCX: 00007f8b46489109
RDX: 0000000000000200 RSI: 0000000020000140 RDI: 0000000000000006
RBP: 00007f8b464e305d R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffc3f8a125f R14: 00007f8b47598300 R15: 0000000000022000
 </TASK>

Showing all locks held in the system:
1 lock held by khungtaskd/29:
 #0: ffffffff8bd840a0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x53/0x260 kernel/locking/lockdep.c:6491
4 locks held by syslogd/2961:
 #0: ffff8880b9b39fd8 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x2b/0x120 kernel/sched/core.c:544
 #1: ffff8880366a6288 (&sb->s_type->i_mutex_key#12){+.+.}-{3:3}, at: psi_task_switch+0x3e7/0x4e0 kernel/sched/psi.c:889
 #2: ffffffff8bd840a0 (rcu_read_lock){....}-{1:2}, at: constant_test_bit arch/x86/include/asm/bitops.h:207 [inline]
 #2: ffffffff8bd840a0 (rcu_read_lock){....}-{1:2}, at: test_bit include/asm-generic/bitops/instrumented-non-atomic.h:135 [inline]
 #2: ffffffff8bd840a0 (rcu_read_lock){....}-{1:2}, at: task_spread_page include/linux/sched.h:1782 [inline]
 #2: ffffffff8bd840a0 (rcu_read_lock){....}-{1:2}, at: cpuset_do_page_mem_spread include/linux/cpuset.h:125 [inline]
 #2: ffffffff8bd840a0 (rcu_read_lock){....}-{1:2}, at: filemap_alloc_folio mm/filemap.c:986 [inline]
 #2: ffffffff8bd840a0 (rcu_read_lock){....}-{1:2}, at: __filemap_get_folio+0xb2/0xf00 mm/filemap.c:1992
 #3: ffffffff8ba14648 (rename_lock.seqcount){+.+.}-{0:0}, at: d_absolute_path+0xef/0x1a0 fs/d_path.c:233
2 locks held by getty/3291:
 #0: ffff88801d5ce098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x22/0x80 drivers/tty/tty_ldisc.c:244
 #1: ffffc90001c682e8 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0xe50/0x13c0 drivers/tty/n_tty.c:2124
3 locks held by syz-executor.3/7789:
3 locks held by syz-executor.3/7794:
 #0: ffff888037a24460 (sb_writers#14){.+.+}-{0:0}, at: do_rmdir+0x1d0/0x430 fs/namei.c:4105
 #1: ffff88803b15d6e0 (&type->i_mutex_dir_key#8/1){+.+.}-{3:3}, at: inode_lock_nested include/linux/fs.h:776 [inline]
 #1: ffff88803b15d6e0 (&type->i_mutex_dir_key#8/1){+.+.}-{3:3}, at: do_rmdir+0x21b/0x430 fs/namei.c:4109
 #2: ffff88803b2f2c30 (&type->i_mutex_dir_key#8){++++}-{3:3}, at: inode_lock include/linux/fs.h:741 [inline]
 #2: ffff88803b2f2c30 (&type->i_mutex_dir_key#8){++++}-{3:3}, at: vfs_rmdir.part.0+0x63/0x5a0 fs/namei.c:4050

=============================================

NMI backtrace for cpu 0
CPU: 0 PID: 29 Comm: khungtaskd Not tainted 5.19.0-rc3-syzkaller-00043-g3abc3ae553c7 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106
 nmi_cpu_backtrace.cold+0x47/0x144 lib/nmi_backtrace.c:111
 nmi_trigger_cpumask_backtrace+0x1e6/0x230 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:146 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:220 [inline]
 watchdog+0xc22/0xf90 kernel/hung_task.c:378
 kthread+0x2e9/0x3a0 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:302
 </TASK>
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 11 Comm: kworker/u4:1 Not tainted 5.19.0-rc3-syzkaller-00043-g3abc3ae553c7 #0

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/06/23 08:53 upstream 3abc3ae553c7 912f5df7 .config console log report info ci-upstream-kasan-gce-selinux-root INFO: task hung in vfs_rmdir
* Struck through repros no longer work on HEAD.