syzbot


INFO: task hung in __f2fs_ioctl

Status: auto-obsoleted due to no activity on 2024/10/17 13:48
Reported-by: syzbot+a7fde87832d320d1104c@syzkaller.appspotmail.com
First crash: 156d, last: 156d
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream INFO: task hung in __f2fs_ioctl (2) f2fs 1 286d 286d 0/28 auto-obsoleted due to no activity on 2024/05/30 13:06
upstream INFO: task hung in __f2fs_ioctl f2fs 21 392d 497d 0/28 auto-obsoleted due to no activity on 2024/01/27 09:43
upstream INFO: task hung in __f2fs_ioctl (3) f2fs 3 130d 172d 0/28 auto-obsoleted due to no activity on 2024/11/02 19:55
linux-5.15 INFO: task hung in __f2fs_ioctl 1 55d 55d 0/3 upstream: reported on 2024/10/19 04:51

Sample crash report:
INFO: task syz.0.600:5777 blocked for more than 143 seconds.
      Not tainted 6.1.97-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz.0.600       state:D stack:27576 pid:5777  ppid:3554   flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5245 [inline]
 __schedule+0x142d/0x4550 kernel/sched/core.c:6558
 schedule+0xbf/0x180 kernel/sched/core.c:6634
 rwsem_down_write_slowpath+0xea1/0x14b0 kernel/locking/rwsem.c:1189
 inode_lock include/linux/fs.h:758 [inline]
 f2fs_ioc_commit_atomic_write fs/f2fs/file.c:2172 [inline]
 __f2fs_ioctl+0x3341/0xc2a0 fs/f2fs/file.c:4225
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:870 [inline]
 __se_sys_ioctl+0xf1/0x160 fs/ioctl.c:856
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x3b/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7fca39b75bd9
RSP: 002b:00007fca3a8fc048 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007fca39d04110 RCX: 00007fca39b75bd9
RDX: 0000000000000000 RSI: 000000000000f502 RDI: 0000000000000004
RBP: 00007fca39be4e60 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000006e R14: 00007fca39d04110 R15: 00007fff7a05f478
 </TASK>

Showing all locks held in the system:
1 lock held by rcu_tasks_kthre/12:
 #0: ffffffff8d12aed0 (rcu_tasks.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x29/0xe30 kernel/rcu/tasks.h:516
1 lock held by rcu_tasks_trace/13:
 #0: ffffffff8d12b6d0 (rcu_tasks_trace.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x29/0xe30 kernel/rcu/tasks.h:516
1 lock held by khungtaskd/28:
 #0: ffffffff8d12ad00 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:350 [inline]
 #0: ffffffff8d12ad00 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:791 [inline]
 #0: ffffffff8d12ad00 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x51/0x290 kernel/locking/lockdep.c:6494
2 locks held by getty/3312:
 #0: ffff888028b94098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x21/0x70 drivers/tty/tty_ldisc.c:244
 #1: ffffc900031262f0 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x6a7/0x1db0 drivers/tty/n_tty.c:2198
2 locks held by kworker/0:4/3594:
 #0: ffff888012472138 ((wq_completion)rcu_gp){+.+.}-{0:0}, at: process_one_work+0x7a9/0x11d0 kernel/workqueue.c:2267
 #1: ffffc900046afd20 ((work_completion)(&rew->rew_work)){+.+.}-{0:0}, at: process_one_work+0x7a9/0x11d0 kernel/workqueue.c:2267
4 locks held by kworker/u4:6/3638:
 #0: ffff888144647938 ((wq_completion)writeback){+.+.}-{0:0}, at: process_one_work+0x7a9/0x11d0 kernel/workqueue.c:2267
 #1: ffffc900048a7d20 ((work_completion)(&(&wb->dwork)->work)){+.+.}-{0:0}, at: process_one_work+0x7a9/0x11d0 kernel/workqueue.c:2267
 #2: ffff888026f520e0 (&type->s_umount_key#50){++++}-{3:3}, at: trylock_super+0x1b/0xf0 fs/super.c:415
 #3: ffff8880639f5140 (&sbi->gc_lock){+.+.}-{3:3}, at: f2fs_down_write fs/f2fs/f2fs.h:2176 [inline]
 #3: ffff8880639f5140 (&sbi->gc_lock){+.+.}-{3:3}, at: f2fs_balance_fs+0x4fb/0x6c0 fs/f2fs/segment.c:428
3 locks held by kworker/0:12/3718:
 #0: ffff888012470938 ((wq_completion)events){+.+.}-{0:0}, at: process_one_work+0x7a9/0x11d0 kernel/workqueue.c:2267
 #1: ffffc90004a17d20 (key_gc_work){+.+.}-{0:0}, at: process_one_work+0x7a9/0x11d0 kernel/workqueue.c:2267
 #2: ffffffff8d1302f8 (rcu_state.exp_mutex){+.+.}-{3:3}, at: exp_funnel_lock kernel/rcu/tree_exp.h:291 [inline]
 #2: ffffffff8d1302f8 (rcu_state.exp_mutex){+.+.}-{3:3}, at: synchronize_rcu_expedited+0x4f0/0x930 kernel/rcu/tree_exp.h:962
2 locks held by syz.0.600/5774:
 #0: ffff888026f52460 (sb_writers#12){.+.+}-{0:0}, at: mnt_want_write+0x3b/0x80 fs/namespace.c:393
 #1: ffff88805d97e2f0 (&sb->s_type->i_mutex_key#25){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:758 [inline]
 #1: ffff88805d97e2f0 (&sb->s_type->i_mutex_key#25){+.+.}-{3:3}, at: do_truncate+0x208/0x300 fs/open.c:63
2 locks held by syz.0.600/5777:
 #0: ffff888026f52460 (sb_writers#12){.+.+}-{0:0}, at: mnt_want_write_file+0x5a/0x1f0 fs/namespace.c:437
 #1: ffff88805d97e2f0 (&sb->s_type->i_mutex_key#25){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:758 [inline]
 #1: ffff88805d97e2f0 (&sb->s_type->i_mutex_key#25){+.+.}-{3:3}, at: f2fs_ioc_commit_atomic_write fs/f2fs/file.c:2172 [inline]
 #1: ffff88805d97e2f0 (&sb->s_type->i_mutex_key#25){+.+.}-{3:3}, at: __f2fs_ioctl+0x3341/0xc2a0 fs/f2fs/file.c:4225
5 locks held by syz.0.600/5779:
1 lock held by syz.3.1285/7970:
 #0: ffffffff8d1301c0 (rcu_state.barrier_mutex){+.+.}-{3:3}, at: rcu_barrier+0x48/0x5f0 kernel/rcu/tree.c:4018

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

NMI backtrace for cpu 1
CPU: 1 PID: 28 Comm: khungtaskd Not tainted 6.1.97-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/07/2024
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106
 nmi_cpu_backtrace+0x4e1/0x560 lib/nmi_backtrace.c:111
 nmi_trigger_cpumask_backtrace+0x1b0/0x3f0 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:148 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:220 [inline]
 watchdog+0xf88/0xfd0 kernel/hung_task.c:377
 kthread+0x28d/0x320 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308
 </TASK>
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 3988 Comm: kworker/u4:9 Not tainted 6.1.97-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/07/2024
Workqueue: bat_events batadv_nc_worker
RIP: 0010:check_preemption_disabled+0x63/0x110 lib/smp_processor_id.c:19
Code: 44 24 08 0f 85 c7 00 00 00 89 d8 48 83 c4 10 5b 41 5c 41 5e 41 5f c3 48 c7 04 24 00 00 00 00 9c 8f 04 24 f7 04 24 00 02 00 00 <74> c9 49 89 f6 49 89 ff 65 4c 8b 25 ed 2c 77 75 41 f6 44 24 2f 04
RSP: 0018:ffffc90009dc7a48 EFLAGS: 00000046
RAX: 0000000080000000 RBX: 0000000000000000 RCX: 1ffff920013b8efc
RDX: dffffc0000000000 RSI: ffffffff8aec13c0 RDI: ffffffff8b3d4760
RBP: ffffc90009dc7be0 R08: dffffc0000000000 R09: fffffbfff2093845
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff920013b8f58
R13: dffffc0000000000 R14: 0000000000000000 R15: 0000000000000246
FS:  0000000000000000(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f53160ce2d8 CR3: 000000007c8cf000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <NMI>
 </NMI>
 <TASK>
 lockdep_recursion_finish kernel/locking/lockdep.c:467 [inline]
 lock_acquire+0x208/0x5a0 kernel/locking/lockdep.c:5664
 rcu_lock_acquire include/linux/rcupdate.h:350 [inline]
 rcu_read_lock include/linux/rcupdate.h:791 [inline]
 batadv_nc_purge_orig_hash net/batman-adv/network-coding.c:408 [inline]
 batadv_nc_worker+0xe8/0x610 net/batman-adv/network-coding.c:719
 process_one_work+0x8a9/0x11d0 kernel/workqueue.c:2292
 worker_thread+0xa47/0x1200 kernel/workqueue.c:2439
 kthread+0x28d/0x320 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308
 </TASK>

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/07/09 13:47 linux-6.1.y 7753af06eebf 79d68ada .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: task hung in __f2fs_ioctl
* Struck through repros no longer work on HEAD.