syzbot


INFO: task hung in blkdev_fallocate

Status: upstream: reported C repro on 2023/03/08 05:38
Bug presence: origin:upstream
[Documentation on labels]
Reported-by: syzbot+dad55e856d8e05000edf@syzkaller.appspotmail.com
First crash: 412d, last: 16d
Fix bisection: failed (error log, bisect log)
  
Bug presence (1)
Date Name Commit Repro Result
2023/05/09 upstream (ToT) ba0ad6ed89fd C [report] INFO: task hung in blkdev_fallocate
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-5.15 INFO: task hung in blkdev_fallocate origin:upstream C error 13 17d 408d 0/3 upstream: reported C repro on 2023/03/12 23:16
upstream INFO: task hung in blkdev_fallocate block C error error 226 4h16m 841d 0/26 upstream: reported C repro on 2022/01/03 09:11

Sample crash report:
INFO: task syz-executor833:3661 blocked for more than 143 seconds.
      Not tainted 6.1.22-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor833 state:D stack:26456 pid:3661  ppid:3658   flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5241 [inline]
 __schedule+0x132c/0x4330 kernel/sched/core.c:6554
 schedule+0xbf/0x180 kernel/sched/core.c:6630
 rwsem_down_write_slowpath+0xe93/0x14a0 kernel/locking/rwsem.c:1189
 filemap_invalidate_lock include/linux/fs.h:801 [inline]
 blkdev_fallocate+0x225/0x390 block/fops.c:656
 vfs_fallocate+0x547/0x6b0 fs/open.c:323
 ksys_fallocate fs/open.c:346 [inline]
 __do_sys_fallocate fs/open.c:354 [inline]
 __se_sys_fallocate fs/open.c:352 [inline]
 __x64_sys_fallocate+0xb9/0x100 fs/open.c:352
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7fa0a2efae39
RSP: 002b:00007ffd2c14a468 EFLAGS: 00000246 ORIG_RAX: 000000000000011d
RAX: ffffffffffffffda RBX: 00000000000f4240 RCX: 00007fa0a2efae39
RDX: 0000000000000000 RSI: 0000000000000011 RDI: 0000000000000004
RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000001
R10: 0008000001002000 R11: 0000000000000246 R12: 00007fa0a2ebe610
R13: 0000000000000000 R14: 00007ffd2c14a490 R15: 00007ffd2c14a480
 </TASK>
INFO: task syz-executor833:3672 blocked for more than 143 seconds.
      Not tainted 6.1.22-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor833 state:D stack:24800 pid:3672  ppid:3654   flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5241 [inline]
 __schedule+0x132c/0x4330 kernel/sched/core.c:6554
 schedule+0xbf/0x180 kernel/sched/core.c:6630
 rwsem_down_write_slowpath+0xe93/0x14a0 kernel/locking/rwsem.c:1189
 filemap_invalidate_lock include/linux/fs.h:801 [inline]
 blkdev_fallocate+0x225/0x390 block/fops.c:656
 vfs_fallocate+0x547/0x6b0 fs/open.c:323
 ksys_fallocate fs/open.c:346 [inline]
 __do_sys_fallocate fs/open.c:354 [inline]
 __se_sys_fallocate fs/open.c:352 [inline]
 __x64_sys_fallocate+0xb9/0x100 fs/open.c:352
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7fa0a2efae39
RSP: 002b:00007ffd2c14a468 EFLAGS: 00000246 ORIG_RAX: 000000000000011d
RAX: ffffffffffffffda RBX: 00000000000f4240 RCX: 00007fa0a2efae39
RDX: 0000000000000000 RSI: 0000000000000011 RDI: 0000000000000004
RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000001
R10: 0008000001002000 R11: 0000000000000246 R12: 0000000000072e5d
R13: 00007ffd2c14a47c R14: 00007ffd2c14a490 R15: 00007ffd2c14a480
 </TASK>

Showing all locks held in the system:
1 lock held by rcu_tasks_kthre/12:
 #0: ffffffff8cf26830 (rcu_tasks.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x29/0xd20 kernel/rcu/tasks.h:510
1 lock held by rcu_tasks_trace/13:
 #0: ffffffff8cf27030 (rcu_tasks_trace.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x29/0xd20 kernel/rcu/tasks.h:510
1 lock held by khungtaskd/28:
 #0: ffffffff8cf26660 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire+0x0/0x30
3 locks held by kworker/1:1H/52:
1 lock held by klogd/2986:
2 locks held by getty/3308:
 #0: ffff88814afc2098 (&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:2177
1 lock held by syz-executor833/3661:
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: filemap_invalidate_lock include/linux/fs.h:801 [inline]
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: blkdev_fallocate+0x225/0x390 block/fops.c:656
1 lock held by syz-executor833/3665:
1 lock held by syz-executor833/3672:
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: filemap_invalidate_lock include/linux/fs.h:801 [inline]
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: blkdev_fallocate+0x225/0x390 block/fops.c:656
1 lock held by syz-executor833/3673:
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: filemap_invalidate_lock include/linux/fs.h:801 [inline]
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: blkdev_fallocate+0x225/0x390 block/fops.c:656
1 lock held by syz-executor833/3681:
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: filemap_invalidate_lock include/linux/fs.h:801 [inline]
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: blkdev_fallocate+0x225/0x390 block/fops.c:656
1 lock held by syz-executor833/3682:
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: filemap_invalidate_lock include/linux/fs.h:801 [inline]
 #0: ffff888140ca4ac0 (mapping.invalidate_lock#2){++++}-{3:3}, at: blkdev_fallocate+0x225/0x390 block/fops.c:656

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

NMI backtrace for cpu 1
CPU: 1 PID: 28 Comm: khungtaskd Not tainted 6.1.22-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023
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+0xf18/0xf60 kernel/hung_task.c:377
 kthread+0x268/0x300 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306
 </TASK>
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 2986 Comm: klogd Not tainted 6.1.22-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023
RIP: 0010:__lock_acquire+0x368/0x1f80 kernel/locking/lockdep.c:4992
Code: 89 2b 48 8d 5c ee 10 48 89 d8 48 c1 e8 03 80 3c 10 00 74 16 48 89 df e8 76 02 76 00 48 8b 34 24 48 ba 00 00 00 00 00 fc ff df <4c> 89 33 48 89 6c 24 20 48 8d 5c ee 18 48 89 d8 48 c1 e8 03 48 89
RSP: 0018:ffffc9000b79f2e0 EFLAGS: 00000046
RAX: 1ffff1100f9a9151 RBX: ffff88807cd48a88 RCX: ffff88807cd48000
RDX: dffffc0000000000 RSI: ffff88807cd48a50 RDI: ffff8880b9840558
RBP: 0000000000000005 R08: 0000000000000001 R09: 0000000000000001
R10: 0000000000000000 R11: dffffc0000000001 R12: 0000000000000000
R13: ffffffff81d397dc R14: ffff8880b9840558 R15: 0000000000000023
FS:  00007f3cfe9da800(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000555555e9a2c0 CR3: 000000007ee4a000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 lock_acquire+0x1f8/0x5a0 kernel/locking/lockdep.c:5669
 __raw_spin_trylock include/linux/spinlock_api_smp.h:90 [inline]
 _raw_spin_trylock+0x42/0x70 kernel/locking/spinlock.c:138
 free_unref_page+0x23c/0x570 mm/page_alloc.c:3505
 free_slab mm/slub.c:2031 [inline]
 discard_slab mm/slub.c:2037 [inline]
 __unfreeze_partials+0x1b7/0x210 mm/slub.c:2586
 put_cpu_partial+0x116/0x180 mm/slub.c:2662
 qlist_free_all+0x22/0x60 mm/kasan/quarantine.c:187
 kasan_quarantine_reduce+0x162/0x180 mm/kasan/quarantine.c:294
 __kasan_slab_alloc+0x1f/0x70 mm/kasan/common.c:305
 kasan_slab_alloc include/linux/kasan.h:201 [inline]
 slab_post_alloc_hook+0x50/0x370 mm/slab.h:737
 slab_alloc_node mm/slub.c:3398 [inline]
 kmem_cache_alloc_node+0x136/0x310 mm/slub.c:3443
 __alloc_skb+0xde/0x620 net/core/skbuff.c:497
 alloc_skb include/linux/skbuff.h:1267 [inline]
 alloc_skb_with_frags+0xa4/0x740 net/core/skbuff.c:6128
 sock_alloc_send_pskb+0x915/0xa50 net/core/sock.c:2721
 unix_dgram_sendmsg+0x5b1/0x2050 net/unix/af_unix.c:1943
 sock_sendmsg_nosec net/socket.c:716 [inline]
 sock_sendmsg net/socket.c:736 [inline]
 __sys_sendto+0x471/0x5f0 net/socket.c:2117
 __do_sys_sendto net/socket.c:2129 [inline]
 __se_sys_sendto net/socket.c:2125 [inline]
 __x64_sys_sendto+0xda/0xf0 net/socket.c:2125
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f3cfeb760ac
Code: 89 02 48 c7 c0 ff ff ff ff eb b8 0f 1f 00 41 89 ca 64 8b 04 25 18 00 00 00 85 c0 75 19 45 31 c9 45 31 c0 b8 2c 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 64 c3 0f 1f 00 55 48 83 ec 20 48 89 54 24 10
RSP: 002b:00007ffc16a79028 EFLAGS: 00000246 ORIG_RAX: 000000000000002c
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f3cfeb760ac
RDX: 000000000000003a RSI: 00005600d4b4ad70 RDI: 0000000000000003
RBP: 00005600d4b46910 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000004000 R11: 0000000000000246 R12: 0000000000000014
R13: 0000000000000001 R14: 00007f3cfecf177d R15: 00007ffc16a79138
 </TASK>
INFO: NMI handler (nmi_cpu_backtrace_handler) took too long to run: 1.343 msecs

Crashes (16):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/04/01 06:15 linux-6.1.y 3b29299e5f60 f325deb0 .config console log report syz C [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: task hung in blkdev_fallocate
2024/03/20 13:59 linux-6.1.y d7543167affd a485f239 .config console log report syz C [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/05/02 03:13 linux-6.1.y ca48fc16c493 62df2017 .config console log report syz C [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/03/13 04:06 linux-6.1.y 1cc3fcf63192 5205ef30 .config console log report syz C [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2024/04/07 22:08 linux-6.1.y 347385861c50 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: task hung in blkdev_fallocate
2024/04/02 04:52 linux-6.1.y e5cd595e23c1 6baf5069 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: task hung in blkdev_fallocate
2024/04/01 12:41 linux-6.1.y e5cd595e23c1 6baf5069 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: task hung in blkdev_fallocate
2024/01/22 13:28 linux-6.1.y 8fd7f4462453 9bd8dcda .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: task hung in blkdev_fallocate
2023/10/28 20:20 linux-6.1.y 32c9cdbe383c 3c418d72 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/03/17 18:30 linux-6.1.y 7eaef76fbc46 7939252e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/03/17 10:45 linux-6.1.y 7eaef76fbc46 18b58603 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/03/16 18:12 linux-6.1.y 6449a0ba6843 18b58603 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/03/14 11:30 linux-6.1.y 6449a0ba6843 0d5c4377 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/03/13 12:28 linux-6.1.y 6449a0ba6843 026e2200 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/03/12 20:22 linux-6.1.y 1cc3fcf63192 5205ef30 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
2023/03/08 05:38 linux-6.1.y 42616e0f09fb d2b00170 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 INFO: task hung in blkdev_fallocate
* Struck through repros no longer work on HEAD.