syzbot


INFO: task hung in fat_count_free_clusters

Status: closed as dup on 2018/10/27 13:33
Subsystems: exfat
[Documentation on labels]
Reported-by: syzbot+f748edfbb0569415706e@syzkaller.appspotmail.com
First crash: 2316d, last: 2136d
Duplicate of
Title Repro Cause bisect Fix bisect Count Last Reported
INFO: rcu detected stall in sys_creat exfat 98 2132d 2223d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
android-49 INFO: task hung in fat_count_free_clusters 2 2314d 2322d 0/3 auto-closed as invalid on 2019/02/22 15:19

Sample crash report:
INFO: task syz-executor4:24910 blocked for more than 140 seconds.
      Not tainted 5.0.0-rc2+ #29
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
syz-executor4   D26736 24910   8313 0x00000004
Call Trace:
 context_switch kernel/sched/core.c:2831 [inline]
 __schedule+0x897/0x1e60 kernel/sched/core.c:3472
 schedule+0xfe/0x350 kernel/sched/core.c:3516
 schedule_preempt_disabled+0x13/0x20 kernel/sched/core.c:3574
 __mutex_lock_common kernel/locking/mutex.c:1002 [inline]
 __mutex_lock+0xa3b/0x1670 kernel/locking/mutex.c:1072
 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:1087
 lock_fat fs/fat/fatent.c:279 [inline]
 fat_count_free_clusters+0x11b/0xe50 fs/fat/fatent.c:656
 fat_statfs+0x3b0/0x4c0 fs/fat/inode.c:822
 statfs_by_dentry fs/statfs.c:64 [inline]
 statfs_by_dentry+0x13d/0x220 fs/statfs.c:53
 vfs_ustat+0x51/0x80 fs/statfs.c:227
 __do_sys_ustat+0xad/0x260 fs/statfs.c:236
 __se_sys_ustat fs/statfs.c:232 [inline]
 __x64_sys_ustat+0x54/0x80 fs/statfs.c:232
 do_syscall_64+0x1a3/0x800 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x457ec9
Code: 6d b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 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 0f 83 3b b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007f18cce7cc78 EFLAGS: 00000246 ORIG_RAX: 0000000000000088
RAX: ffffffffffffffda RBX: 0000000000000002 RCX: 0000000000457ec9
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000700
RBP: 000000000073bfa0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007f18cce7d6d4
R13: 00000000004c6b9b R14: 00000000004dc0c8 R15: 00000000ffffffff

Showing all locks held in the system:
1 lock held by khungtaskd/1042:
 #0: 00000000bd3257f3 (rcu_read_lock){....}, at: debug_show_all_locks+0xc6/0x41d kernel/locking/lockdep.c:4389
2 locks held by rs:main Q:Reg/8177:
 #0: 00000000bdcfb4ba (&f->f_pos_lock){+.+.}, at: __fdget_pos+0x1b3/0x1f0 fs/file.c:795
 #1: 00000000136dca44 (sb_writers#3){.+.+}, at: file_start_write include/linux/fs.h:2815 [inline]
 #1: 00000000136dca44 (sb_writers#3){.+.+}, at: vfs_write+0x429/0x580 fs/read_write.c:548
1 lock held by rsyslogd/8179:
 #0: 00000000f0c7d4e8 (&f->f_pos_lock){+.+.}, at: __fdget_pos+0x1b3/0x1f0 fs/file.c:795
2 locks held by getty/8269:
 #0: 000000001b56af2b (&tty->ldisc_sem){++++}, at: ldsem_down_read+0x33/0x40 drivers/tty/tty_ldsem.c:341
 #1: 000000002271ada6 (&ldata->atomic_read_lock){+.+.}, at: n_tty_read+0x30a/0x1eb0 drivers/tty/n_tty.c:2154
2 locks held by getty/8270:
 #0: 00000000050e1949 (&tty->ldisc_sem){++++}, at: ldsem_down_read+0x33/0x40 drivers/tty/tty_ldsem.c:341
 #1: 00000000bb246dd5 (&ldata->atomic_read_lock){+.+.}, at: n_tty_read+0x30a/0x1eb0 drivers/tty/n_tty.c:2154
2 locks held by getty/8271:
 #0: 00000000491c29bc (&tty->ldisc_sem){++++}, at: ldsem_down_read+0x33/0x40 drivers/tty/tty_ldsem.c:341
 #1: 00000000dcbbeb16 (&ldata->atomic_read_lock){+.+.}, at: n_tty_read+0x30a/0x1eb0 drivers/tty/n_tty.c:2154
2 locks held by getty/8272:
 #0: 000000006da10d9c (&tty->ldisc_sem){++++}, at: ldsem_down_read+0x33/0x40 drivers/tty/tty_ldsem.c:341
 #1: 00000000a39843fe (&ldata->atomic_read_lock){+.+.}, at: n_tty_read+0x30a/0x1eb0 drivers/tty/n_tty.c:2154
2 locks held by getty/8273:
 #0: 0000000065faa932 (&tty->ldisc_sem){++++}, at: ldsem_down_read+0x33/0x40 drivers/tty/tty_ldsem.c:341
 #1: 0000000015a7c7a8 (&ldata->atomic_read_lock){+.+.}, at: n_tty_read+0x30a/0x1eb0 drivers/tty/n_tty.c:2154
2 locks held by getty/8274:
 #0: 000000005043cd2e (&tty->ldisc_sem){++++}, at: ldsem_down_read+0x33/0x40 drivers/tty/tty_ldsem.c:341
 #1: 000000009d0ce33b (&ldata->atomic_read_lock){+.+.}, at: n_tty_read+0x30a/0x1eb0 drivers/tty/n_tty.c:2154
2 locks held by getty/8275:
 #0: 0000000036d16fef (&tty->ldisc_sem){++++}, at: ldsem_down_read+0x33/0x40 drivers/tty/tty_ldsem.c:341
 #1: 00000000fc3df2cd (&ldata->atomic_read_lock){+.+.}, at: n_tty_read+0x30a/0x1eb0 drivers/tty/n_tty.c:2154
3 locks held by syz-executor4/24868:
2 locks held by syz-executor4/24910:
 #0: 00000000c3574808 (&type->s_umount_key#51){++++}, at: user_get_super+0x13f/0x250 fs/super.c:822
 #1: 0000000028575e80 (&sbi->fat_lock){+.+.}, at: lock_fat fs/fat/fatent.c:279 [inline]
 #1: 0000000028575e80 (&sbi->fat_lock){+.+.}, at: fat_count_free_clusters+0x11b/0xe50 fs/fat/fatent.c:656

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

NMI backtrace for cpu 1
CPU: 1 PID: 1042 Comm: khungtaskd Not tainted 5.0.0-rc2+ #29
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:77 [inline]
 dump_stack+0x1db/0x2d0 lib/dump_stack.c:113
 nmi_cpu_backtrace.cold+0x63/0xa4 lib/nmi_backtrace.c:101
 nmi_trigger_cpumask_backtrace+0x1be/0x236 lib/nmi_backtrace.c:62
 arch_trigger_cpumask_backtrace+0x14/0x20 arch/x86/kernel/apic/hw_nmi.c:38
 trigger_all_cpu_backtrace include/linux/nmi.h:146 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:203 [inline]
 watchdog+0xbbb/0x1170 kernel/hung_task.c:287
 kthread+0x357/0x430 kernel/kthread.c:246
 ret_from_fork+0x3a/0x50 arch/x86/entry/entry_64.S:352
Sending NMI from CPU 1 to CPUs 0:
INFO: NMI handler (nmi_cpu_backtrace_handler) took too long to run: 1.194 msecs
NMI backtrace for cpu 0
CPU: 0 PID: 24868 Comm: syz-executor4 Not tainted 5.0.0-rc2+ #29
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:match_held_lock+0x2e2/0x780 kernel/locking/lockdep.c:3398
Code: 89 5e a0 48 b8 00 00 00 00 00 fc ff df 41 c6 04 07 f8 75 49 31 c0 48 ba 00 00 00 00 00 fc ff df 4c 01 e2 48 c7 02 00 00 00 00 <c7> 42 08 00 00 00 00 48 8b 75 d0 65 48 33 34 25 28 00 00 00 0f 85
RSP: 0018:ffff88804db97050 EFLAGS: 00000082
RAX: 0000000000000000 RBX: ffff88804e5103c0 RCX: dffffc0000000000
RDX: ffffed1009b72e0e RSI: ffffffff899a3f00 RDI: ffff88804e510c62
RBP: ffff88804db97118 R08: ffff88804e5103c0 R09: ffffed1015cc5b90
R10: ffffed1015cc5b8f R11: ffff8880ae62dc7b R12: 1ffff11009b72e0e
R13: ffff88804e510c40 R14: ffff88804db970f0 R15: ffff88804e510c40
FS:  00007f18cce9e700(0000) GS:ffff8880ae600000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffff600400 CR3: 0000000095f75000 CR4: 00000000001426f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000600
Call Trace:
 __lock_is_held+0xb6/0x140 kernel/locking/lockdep.c:3661
 lock_is_held_type+0x110/0x210 kernel/locking/lockdep.c:3879
 lock_is_held include/linux/lockdep.h:337 [inline]
 rcu_read_lock_held kernel/rcu/update.c:281 [inline]
 rcu_read_lock_held+0xa3/0xd0 kernel/rcu/update.c:273
 xa_head include/linux/xarray.h:886 [inline]
 xas_start+0x2dd/0x720 lib/xarray.c:182
 xas_load+0x21/0x160 lib/xarray.c:227
 find_get_entry+0x350/0x10a0 mm/filemap.c:1476
 pagecache_get_page+0xe6/0x1020 mm/filemap.c:1579
 find_get_page_flags include/linux/pagemap.h:278 [inline]
 __find_get_block_slow fs/buffer.c:205 [inline]
 __find_get_block fs/buffer.c:1294 [inline]
 __find_get_block+0x615/0xf20 fs/buffer.c:1288
 __getblk_slow fs/buffer.c:1039 [inline]
 __getblk_gfp+0x295/0xd20 fs/buffer.c:1320
 __bread_gfp+0x2f/0x300 fs/buffer.c:1354
 sb_bread include/linux/buffer_head.h:307 [inline]
 fat_ent_bread+0x16c/0x290 fs/fat/fatent.c:107
 fat_ent_read_block fs/fat/fatent.c:440 [inline]
 fat_count_free_clusters+0x68c/0xe50 fs/fat/fatent.c:675
 fat_statfs+0x3b0/0x4c0 fs/fat/inode.c:822
 statfs_by_dentry fs/statfs.c:64 [inline]
 statfs_by_dentry+0x13d/0x220 fs/statfs.c:53
 vfs_ustat+0x51/0x80 fs/statfs.c:227
 __do_sys_ustat+0xad/0x260 fs/statfs.c:236
 __se_sys_ustat fs/statfs.c:232 [inline]
 __x64_sys_ustat+0x54/0x80 fs/statfs.c:232
 do_syscall_64+0x1a3/0x800 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x457ec9
Code: 6d b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 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 0f 83 3b b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007f18cce9dc78 EFLAGS: 00000246 ORIG_RAX: 0000000000000088
RAX: ffffffffffffffda RBX: 0000000000000002 RCX: 0000000000457ec9
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000700
RBP: 000000000073bf00 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007f18cce9e6d4
R13: 00000000004c6b9b R14: 00000000004dc0c8 R15: 00000000ffffffff

Crashes (6):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/01/16 19:30 upstream 47bfa6d9dc8c d538790b .config console log report ci-upstream-kasan-gce-smack-root
2019/01/16 16:13 upstream 47bfa6d9dc8c d538790b .config console log report ci-upstream-kasan-gce-selinux-root
2019/01/04 17:52 upstream 96d4f267e40f 0127e3ba .config console log report ci-upstream-kasan-gce-smack-root
2018/11/13 17:51 upstream ccda4af0f4b9 5f5f6d14 .config console log report ci-upstream-kasan-gce-root
2018/09/23 15:38 upstream 328c6333ba3d 37079712 .config console log report ci-upstream-kasan-gce-selinux-root
2018/07/20 14:07 linux-next 89cf55353308 49f35839 .config console log report ci-upstream-linux-next-kasan-gce-root
* Struck through repros no longer work on HEAD.