syzbot


INFO: task hung in __generic_file_fsync

Status: auto-closed as invalid on 2020/01/02 10:29
Reported-by: syzbot+a376a04f49b313905704@syzkaller.appspotmail.com
First crash: 1905d, last: 1905d
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 INFO: task hung in __generic_file_fsync ext4 C 211 629d 1062d 0/1 upstream: reported C repro on 2021/12/25 03:26
upstream INFO: task hung in __generic_file_fsync (3) exfat ntfs3 C inconclusive done 8 327d 834d 25/28 fixed on 2024/02/21 18:23
upstream INFO: task hung in __generic_file_fsync (2) fs mm C done done 28 1784d 1785d 15/28 fixed on 2020/02/18 10:28

Sample crash report:
device lo left promiscuous mode
device lo entered promiscuous mode
SELinux: unrecognized netlink message: protocol=0 nlmsg_type=0 sclass=netlink_route_socket pig=24133 comm=syz-executor.0
INFO: task syz-executor.0:24125 blocked for more than 140 seconds.
      Not tainted 4.9.141+ #1
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
syz-executor.0  D27528 24125   2087 0x00000004
 ffff8801a8b417c0 ffff8801d4c7ac00 ffff8801a705c780 ffff8801a8b40000
 ffff8801db621018 ffff88016cd7f530 ffffffff828075c2 ffff8801a8b42070
 1ffff1002d9afe9a ffffffff83c48878 0000000041b58ab3 ffff8801db6218f0
Call Trace:
 [<ffffffff82808aef>] schedule+0x7f/0x1b0 kernel/sched/core.c:3553
 [<ffffffff828142d5>] schedule_timeout+0x735/0xe20 kernel/time/timer.c:1771
 [<ffffffff82806d8a>] io_schedule_timeout+0x1ba/0x390 kernel/sched/core.c:5176
 [<ffffffff82809eb9>] io_schedule include/linux/sched.h:460 [inline]
 [<ffffffff82809eb9>] bit_wait_io+0x19/0xa0 kernel/sched/wait.c:582
 [<ffffffff828096b3>] __wait_on_bit+0x93/0x120 kernel/sched/wait.c:383
 [<ffffffff8140ab80>] wait_on_page_bit+0x130/0x140 mm/filemap.c:800
 [<ffffffff8140ad35>] wait_on_page_writeback include/linux/pagemap.h:534 [inline]
 [<ffffffff8140ad35>] __filemap_fdatawait_range+0x1a5/0x270 mm/filemap.c:451
 [<ffffffff8140ae25>] filemap_fdatawait_range+0x25/0x50 mm/filemap.c:481
 [<ffffffff81411cb5>] filemap_write_and_wait_range+0x85/0xb0 mm/filemap.c:582
 [<ffffffff8158b803>] __generic_file_fsync+0x93/0x1a0 fs/libfs.c:974
 [<ffffffff816b5209>] ext4_sync_file+0x659/0x10a0 fs/ext4/fsync.c:116
 [<ffffffff815b195c>] vfs_fsync_range+0x10c/0x260 fs/sync.c:195
 [<ffffffff816b346f>] generic_write_sync include/linux/fs.h:2607 [inline]
 [<ffffffff816b346f>] ext4_file_write_iter+0x81f/0xd70 fs/ext4/file.c:169
 [<ffffffff81508347>] new_sync_write fs/read_write.c:496 [inline]
 [<ffffffff81508347>] __vfs_write+0x3d7/0x580 fs/read_write.c:509
 [<ffffffff8150ab97>] vfs_write+0x187/0x520 fs/read_write.c:557
 [<ffffffff8150e9c9>] SYSC_write fs/read_write.c:604 [inline]
 [<ffffffff8150e9c9>] SyS_write+0xd9/0x1c0 fs/read_write.c:596
 [<ffffffff810056ef>] do_syscall_64+0x19f/0x550 arch/x86/entry/common.c:285
 [<ffffffff82817893>] entry_SYSCALL_64_after_swapgs+0x5d/0xdb

Showing all locks held in the system:
2 locks held by khungtaskd/24:
 #0:  (rcu_read_lock){......}, at: [<ffffffff8131c0cc>] check_hung_uninterruptible_tasks kernel/hung_task.c:168 [inline]
 #0:  (rcu_read_lock){......}, at: [<ffffffff8131c0cc>] watchdog+0x11c/0xa20 kernel/hung_task.c:239
 #1:  (tasklist_lock){.+.+..}, at: [<ffffffff813fe63f>] debug_show_all_locks+0x79/0x218 kernel/locking/lockdep.c:4336
2 locks held by getty/2028:
 #0:  (&tty->ldisc_sem){++++++}, at: [<ffffffff82815952>] ldsem_down_read+0x32/0x40 drivers/tty/tty_ldsem.c:367
 #1:  (&ldata->atomic_read_lock){+.+.+.}, at: [<ffffffff81d37362>] n_tty_read+0x202/0x16e0 drivers/tty/n_tty.c:2142
2 locks held by syz-executor.0/24125:
 #0:  (&f->f_pos_lock){+.+.+.}, at: [<ffffffff8156cc7c>] __fdget_pos+0xac/0xd0 fs/file.c:781
 #1:  (sb_writers#4){.+.+.+}, at: [<ffffffff8150adfb>] file_start_write include/linux/fs.h:2640 [inline]
 #1:  (sb_writers#4){.+.+.+}, at: [<ffffffff8150adfb>] vfs_write+0x3eb/0x520 fs/read_write.c:556
3 locks held by syz-executor.0/24140:
 #0:  (sb_writers#4){.+.+.+}, at: [<ffffffff815755ef>] sb_start_write include/linux/fs.h:1573 [inline]
 #0:  (sb_writers#4){.+.+.+}, at: [<ffffffff815755ef>] mnt_want_write+0x3f/0xb0 fs/namespace.c:391
 #1:  (&sb->s_type->i_mutex_key#9){++++++}, at: [<ffffffff81503378>] inode_lock include/linux/fs.h:766 [inline]
 #1:  (&sb->s_type->i_mutex_key#9){++++++}, at: [<ffffffff81503378>] do_truncate2+0x128/0x1f0 fs/open.c:61
 #2:  (&ei->i_mmap_sem){++++.+}, at: [<ffffffff816e52f8>] ext4_setattr+0x11e8/0x2170 fs/ext4/inode.c:5296
3 locks held by syz-executor.0/24142:
 #0:  (&f->f_pos_lock){+.+.+.}, at: [<ffffffff8156cc7c>] __fdget_pos+0xac/0xd0 fs/file.c:781
 #1:  (sb_writers#4){.+.+.+}, at: [<ffffffff8150adfb>] file_start_write include/linux/fs.h:2640 [inline]
 #1:  (sb_writers#4){.+.+.+}, at: [<ffffffff8150adfb>] vfs_write+0x3eb/0x520 fs/read_write.c:556
 #2:  (&sb->s_type->i_mutex_key#9){++++++}, at: [<ffffffff816b2d72>] inode_lock include/linux/fs.h:766 [inline]
 #2:  (&sb->s_type->i_mutex_key#9){++++++}, at: [<ffffffff816b2d72>] ext4_file_write_iter+0x122/0xd70 fs/ext4/file.c:100
2 locks held by syz-executor.4/24104:
 #0:  (sb_writers#4){.+.+.+}, at: [<ffffffff8150dd10>] file_start_write include/linux/fs.h:2640 [inline]
 #0:  (sb_writers#4){.+.+.+}, at: [<ffffffff8150dd10>] do_sendfile+0xa80/0xc30 fs/read_write.c:1392
 #1:  (&sb->s_type->i_mutex_key#9){++++++}, at: [<ffffffff816b2d72>] inode_lock include/linux/fs.h:766 [inline]
 #1:  (&sb->s_type->i_mutex_key#9){++++++}, at: [<ffffffff816b2d72>] ext4_file_write_iter+0x122/0xd70 fs/ext4/file.c:100
2 locks held by syz-executor.5/24127:
 #0:  (sb_writers#4){.+.+.+}, at: [<ffffffff8150dd10>] file_start_write include/linux/fs.h:2640 [inline]
 #0:  (sb_writers#4){.+.+.+}, at: [<ffffffff8150dd10>] do_sendfile+0xa80/0xc30 fs/read_write.c:1392
 #1:  (&sb->s_type->i_mutex_key#9){++++++}, at: [<ffffffff816b2d72>] inode_lock include/linux/fs.h:766 [inline]
 #1:  (&sb->s_type->i_mutex_key#9){++++++}, at: [<ffffffff816b2d72>] ext4_file_write_iter+0x122/0xd70 fs/ext4/file.c:100

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

NMI backtrace for cpu 0
CPU: 0 PID: 24 Comm: khungtaskd Not tainted 4.9.141+ #1
 ffff8801d9907d08 ffffffff81b42e79 0000000000000000 0000000000000000
 0000000000000000 0000000000000001 ffffffff810983b0 ffff8801d9907d40
 ffffffff81b4df89 0000000000000000 0000000000000000 0000000000000002
Call Trace:
 [<ffffffff81b42e79>] __dump_stack lib/dump_stack.c:15 [inline]
 [<ffffffff81b42e79>] dump_stack+0xc1/0x128 lib/dump_stack.c:51
 [<ffffffff81b4df89>] nmi_cpu_backtrace.cold.0+0x48/0x87 lib/nmi_backtrace.c:99
 [<ffffffff81b4df1c>] nmi_trigger_cpumask_backtrace+0x12c/0x151 lib/nmi_backtrace.c:60
 [<ffffffff810984b4>] arch_trigger_cpumask_backtrace+0x14/0x20 arch/x86/kernel/apic/hw_nmi.c:37
 [<ffffffff8131c65d>] trigger_all_cpu_backtrace include/linux/nmi.h:58 [inline]
 [<ffffffff8131c65d>] check_hung_task kernel/hung_task.c:125 [inline]
 [<ffffffff8131c65d>] check_hung_uninterruptible_tasks kernel/hung_task.c:182 [inline]
 [<ffffffff8131c65d>] watchdog+0x6ad/0xa20 kernel/hung_task.c:239
 [<ffffffff81142c3d>] kthread+0x26d/0x300 kernel/kthread.c:211
 [<ffffffff82817a5c>] ret_from_fork+0x5c/0x70 arch/x86/entry/entry_64.S:373
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1 skipped: idling at pc 0xffffffff82816496

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/09/04 10:28 https://android.googlesource.com/kernel/common android-4.9 8fe428403e30 12381952 .config console log report ci-android-49-kasan-gce
* Struck through repros no longer work on HEAD.