syzbot


INFO: task hung in __closure_sync_timeout

Status: upstream: reported C repro on 2024/10/22 13:19
Subsystems: bcachefs
[Documentation on labels]
Reported-by: syzbot+43d0c6eb00a26a41ec60@syzkaller.appspotmail.com
First crash: 33d, last: 3d03h
Cause bisection: introduced by (bisect log) :
commit f7643bc9749f270d487c32dc35b578575bf1adb0
Author: Kent Overstreet <kent.overstreet@linux.dev>
Date: Wed Apr 17 05:26:02 2024 +0000

  bcachefs: make btree read errors silent during scan

Crash: invalid opcode in bch2_fs_btree_cache_exit (log)
Repro: C syz .config
  
Discussions (2)
Title Replies (including bot) Last reply
[syzbot] Monthly bcachefs report (Nov 2024) 0 (1) 2024/11/15 10:49
[syzbot] [bcachefs?] INFO: task hung in __closure_sync_timeout 0 (2) 2024/10/22 22:39

Sample crash report:
INFO: task bch-copygc/loop:5858 blocked for more than 143 seconds.
      Not tainted 6.12.0-rc6-syzkaller-00169-g906bd684e4b1 #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:bch-copygc/loop state:D stack:20112 pid:5858  tgid:5858  ppid:2      flags:0x00004000
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5328 [inline]
 __schedule+0x17fa/0x4bd0 kernel/sched/core.c:6690
 __schedule_loop kernel/sched/core.c:6767 [inline]
 schedule+0x14b/0x320 kernel/sched/core.c:6782
 schedule_timeout+0x1be/0x310 kernel/time/timer.c:2615
 __closure_sync_timeout+0x2d8/0x450 lib/closure.c:217
 closure_sync_timeout include/linux/closure.h:206 [inline]
 __bch2_wait_on_allocator+0x11a/0x250 fs/bcachefs/alloc_foreground.c:1812
 bch2_wait_on_allocator fs/bcachefs/alloc_foreground.h:239 [inline]
 __bch2_write+0x562a/0x5dd0 fs/bcachefs/io_write.c:1504
 bch2_write+0x9b5/0x1760 fs/bcachefs/io_write.c:1634
 closure_queue include/linux/closure.h:270 [inline]
 closure_call include/linux/closure.h:432 [inline]
 bch2_data_update_read_done+0x22e/0x330 fs/bcachefs/data_update.c:426
 move_write fs/bcachefs/move.c:133 [inline]
 bch2_moving_ctxt_do_pending_writes+0x44c/0x8d0 fs/bcachefs/move.c:164
 bch2_move_ratelimit+0x76c/0xeb0 fs/bcachefs/move.c:492
 bch2_evacuate_bucket+0x26b3/0x3620 fs/bcachefs/move.c:702
 bch2_copygc+0x42c9/0x4ca0 fs/bcachefs/movinggc.c:240
 bch2_copygc_thread+0x737/0xc20 fs/bcachefs/movinggc.c:381
 kthread+0x2f0/0x390 kernel/kthread.c:389
 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
 </TASK>

Showing all locks held in the system:
1 lock held by khungtaskd/30:
 #0: ffffffff8e937da0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:337 [inline]
 #0: ffffffff8e937da0 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline]
 #0: ffffffff8e937da0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x55/0x2a0 kernel/locking/lockdep.c:6720
2 locks held by getty/5592:
 #0: ffff8880310540a0 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x25/0x70 drivers/tty/tty_ldisc.c:243
 #1: ffffc90002f062f0 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x6a6/0x1e00 drivers/tty/n_tty.c:2211
2 locks held by syz-executor800/6206:

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

NMI backtrace for cpu 1
CPU: 1 UID: 0 PID: 30 Comm: khungtaskd Not tainted 6.12.0-rc6-syzkaller-00169-g906bd684e4b1 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/30/2024
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:94 [inline]
 dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
 nmi_cpu_backtrace+0x49c/0x4d0 lib/nmi_backtrace.c:113
 nmi_trigger_cpumask_backtrace+0x198/0x320 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:162 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:223 [inline]
 watchdog+0xff4/0x1040 kernel/hung_task.c:379
 kthread+0x2f0/0x390 kernel/kthread.c:389
 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
 </TASK>
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 UID: 0 PID: 5190 Comm: klogd Not tainted 6.12.0-rc6-syzkaller-00169-g906bd684e4b1 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/30/2024
RIP: 0033:0x7f5bf48ea500
Code: fc ff ff 45 85 db 74 22 eb cd 4c 89 c0 48 c1 e8 0c 49 33 00 48 89 04 d7 66 42 ff 0c 6f 49 c7 40 08 00 00 00 00 e9 16 04 00 00 <48> 81 fb ff 03 00 00 0f 86 9c 00 00 00 43 8d 44 24 fe 48 8d 44 c5
RSP: 002b:00007ffcb47918d0 EFLAGS: 00000246
RAX: 671de4c05b4bf30d RBX: 0000000000002010 RCX: 0000000000000000
RDX: 00007f5bf4a13b00 RSI: 0000000000000000 RDI: 0000564e23958010
RBP: 00007f5bf4a13aa0 R08: 0000000000000004 R09: 0000000000000000
R10: 000000000000020f R11: 0000000000000000 R12: 000000000000006b
R13: 00000000000001ff R14: 00007f5bf4a13b00 R15: 0000000000000000
FS:  00007f5bf47e4380 GS:  0000000000000000

Crashes (2353):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/11/08 12:35 upstream 906bd684e4b1 179b040e .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/08 08:47 upstream 906bd684e4b1 179b040e .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/07 03:50 upstream 7758b206117d df3dc63b .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/06 22:10 upstream 7758b206117d df3dc63b .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/02 23:11 upstream 11066801dd4b f00eed24 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/02 21:56 upstream 11066801dd4b f00eed24 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/01 15:42 upstream 6c52d4da1c74 96eb609f .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/10/31 05:58 upstream 4236f913808c 96eb609f .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/10/25 13:04 upstream ae90f6a6170d c79b8ca5 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/10/25 05:44 upstream 4e46774408d9 c79b8ca5 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/10/22 22:06 upstream c2ee9f594da8 a93682b3 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/10/22 11:04 upstream c2ee9f594da8 a93682b3 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 17:55 upstream 0a9b9d17f3a7 77f3eeb7 .config console log report syz / log C [disk image (non-bootable)] [vmlinux] [kernel image] [mounted in repro] ci-snapshot-upstream-root INFO: task hung in __closure_sync_timeout
2024/11/13 04:45 upstream 3022e9d00ebe 62026c85 .config console log report syz / log C [disk image (non-bootable)] [vmlinux] [kernel image] [mounted in repro] ci-snapshot-upstream-root INFO: task hung in __closure_sync_timeout
2024/11/09 18:56 linux-next 929beafbe7ac 6b856513 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-linux-next-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/11 14:47 upstream 2d5404caa8c7 0c4b1325 .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/15 01:16 upstream 0a9b9d17f3a7 77f3eeb7 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/14 23:19 upstream 0a9b9d17f3a7 77f3eeb7 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/14 21:48 upstream 0a9b9d17f3a7 77f3eeb7 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/14 19:02 upstream 0a9b9d17f3a7 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 16:48 upstream 0a9b9d17f3a7 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 15:17 upstream 0a9b9d17f3a7 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 13:48 upstream 0a9b9d17f3a7 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 12:47 upstream 0a9b9d17f3a7 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 11:46 upstream 0a9b9d17f3a7 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 09:40 upstream 0a9b9d17f3a7 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 08:12 upstream 0a9b9d17f3a7 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 06:23 upstream 0a9b9d17f3a7 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 05:03 upstream 0a9b9d17f3a7 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 02:22 upstream 0a9b9d17f3a7 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/14 01:19 upstream f1b785f4c787 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/13 23:24 upstream f1b785f4c787 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 22:11 upstream f1b785f4c787 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 22:02 upstream f1b785f4c787 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 20:56 upstream f1b785f4c787 a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/13 19:02 upstream f1b785f4c787 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 17:29 upstream f1b785f4c787 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 14:17 upstream f1b785f4c787 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 12:44 upstream f1b785f4c787 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 11:29 upstream f1b785f4c787 bb3f8425 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 09:58 upstream 3022e9d00ebe 62026c85 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/13 03:37 upstream 3022e9d00ebe 62026c85 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/12 21:57 upstream 3022e9d00ebe 75bb1b32 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/12 21:02 upstream 3022e9d00ebe 62026c85 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/12 19:58 upstream 3022e9d00ebe 62026c85 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/12 18:21 upstream 2d5404caa8c7 75bb1b32 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/12 17:15 upstream 2d5404caa8c7 75bb1b32 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/12 17:13 upstream 2d5404caa8c7 75bb1b32 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/12 14:10 upstream 2d5404caa8c7 75bb1b32 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/12 12:57 upstream 2d5404caa8c7 75bb1b32 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/12 10:31 upstream 2d5404caa8c7 75bb1b32 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/12 08:52 upstream 2d5404caa8c7 75bb1b32 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/10/18 10:31 upstream 4d939780b705 666f77ed .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs INFO: task hung in __closure_sync_timeout
2024/11/13 16:17 linux-next 929beafbe7ac 62026c85 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/13 02:17 linux-next 929beafbe7ac 62026c85 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root INFO: task hung in __closure_sync_timeout
2024/11/18 03:12 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci 887407160d72 cfe3a04a .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
2024/11/17 18:35 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci 887407160d72 cfe3a04a .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
2024/11/17 17:09 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci 887407160d72 cfe3a04a .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
2024/11/17 01:21 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci 887407160d72 cfe3a04a .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
2024/11/16 18:26 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci 887407160d72 cfe3a04a .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
2024/11/16 01:26 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci 887407160d72 cfe3a04a .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
2024/11/15 22:56 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci 887407160d72 f6ede3a3 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
2024/11/14 03:38 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci 8e9a54d7181b a8c99394 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
2024/11/13 08:01 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci baa007e8da32 62026c85 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 INFO: task hung in __closure_sync_timeout
* Struck through repros no longer work on HEAD.