INFO: task kworker/u8:3:52 blocked for more than 143 seconds. Not tainted 6.13.0-rc4-syzkaller-00012-g9b2ffa6148b1 #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. task:kworker/u8:3 state:D stack:14000 pid:52 tgid:52 ppid:2 flags:0x00004000 Workqueue: writeback wb_workfn (flush-bcachefs-57) Call Trace: context_switch kernel/sched/core.c:5369 [inline] __schedule+0x17fb/0x4be0 kernel/sched/core.c:6756 __schedule_loop kernel/sched/core.c:6833 [inline] schedule+0x14b/0x320 kernel/sched/core.c:6848 io_schedule+0x8d/0x110 kernel/sched/core.c:7681 folio_wait_bit_common+0x839/0xee0 mm/filemap.c:1308 folio_lock include/linux/pagemap.h:1151 [inline] writeback_get_folio mm/page-writeback.c:2515 [inline] writeback_iter+0x8ad/0x12b0 mm/page-writeback.c:2609 write_cache_pages+0xb1/0x230 mm/page-writeback.c:2658 bch2_writepages+0x156/0x390 fs/bcachefs/fs-io-buffered.c:639 do_writepages+0x35f/0x880 mm/page-writeback.c:2702 __writeback_single_inode+0x14f/0x10d0 fs/fs-writeback.c:1680 writeback_sb_inodes+0x820/0x1360 fs/fs-writeback.c:1976 __writeback_inodes_wb+0x11b/0x260 fs/fs-writeback.c:2047 wb_writeback+0x427/0xb80 fs/fs-writeback.c:2158 wb_check_background_flush fs/fs-writeback.c:2228 [inline] wb_do_writeback fs/fs-writeback.c:2316 [inline] wb_workfn+0xc4b/0x1080 fs/fs-writeback.c:2343 process_one_work kernel/workqueue.c:3229 [inline] process_scheduled_works+0xa66/0x1840 kernel/workqueue.c:3310 worker_thread+0x870/0xd30 kernel/workqueue.c:3391 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 INFO: task syz.1.394:9615 blocked for more than 143 seconds. Not tainted 6.13.0-rc4-syzkaller-00012-g9b2ffa6148b1 #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. task:syz.1.394 state:D stack:26192 pid:9615 tgid:9546 ppid:8917 flags:0x00004004 Call Trace: context_switch kernel/sched/core.c:5369 [inline] __schedule+0x17fb/0x4be0 kernel/sched/core.c:6756 __schedule_loop kernel/sched/core.c:6833 [inline] schedule+0x14b/0x320 kernel/sched/core.c:6848 io_schedule+0x8d/0x110 kernel/sched/core.c:7681 folio_wait_bit_common+0x839/0xee0 mm/filemap.c:1308 folio_wait_writeback+0xb0/0x100 mm/page-writeback.c:3194 truncate_inode_partial_folio+0x169/0x5e0 mm/truncate.c:192 truncate_inode_pages_range+0x6f3/0x10e0 mm/truncate.c:338 bchfs_fpunch+0x1c1/0x780 fs/bcachefs/fs-io.c:514 bch2_fallocate_dispatch+0x3e4/0x540 fs/bcachefs/fs-io.c:782 vfs_fallocate+0x569/0x6e0 fs/open.c:327 do_vfs_ioctl+0x258c/0x2e40 fs/ioctl.c:885 __do_sys_ioctl fs/ioctl.c:904 [inline] __se_sys_ioctl+0x80/0x170 fs/ioctl.c:892 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f7fd1185d29 RSP: 002b:00007f7fcefd5038 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007f7fd1376160 RCX: 00007f7fd1185d29 RDX: 00000000200000c0 RSI: 0000000040305829 RDI: 0000000000000008 RBP: 00007f7fd1201aa8 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 00007f7fd1376160 R15: 00007ffe79141d48 Showing all locks held in the system: 1 lock held by pool_workqueue_/3: 1 lock held by khungtaskd/30: #0: ffffffff8e937ae0 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:337 [inline] #0: ffffffff8e937ae0 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline] #0: ffffffff8e937ae0 (rcu_read_lock){....}-{1:3}, at: debug_show_all_locks+0x55/0x2a0 kernel/locking/lockdep.c:6744 3 locks held by kworker/u8:2/35: 3 locks held by kworker/u8:3/52: #0: ffff888020aa1948 ((wq_completion)writeback){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:3204 [inline] #0: ffff888020aa1948 ((wq_completion)writeback){+.+.}-{0:0}, at: process_scheduled_works+0x93b/0x1840 kernel/workqueue.c:3310 #1: ffffc90000bc7d00 ((work_completion)(&(&wb->dwork)->work)){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:3205 [inline] #1: ffffc90000bc7d00 ((work_completion)(&(&wb->dwork)->work)){+.+.}-{0:0}, at: process_scheduled_works+0x976/0x1840 kernel/workqueue.c:3310 #2: ffff88802a4c00e0 (&type->s_umount_key#69){++++}-{4:4}, at: super_trylock_shared+0x22/0xf0 fs/super.c:562 1 lock held by kworker/u8:6/1130: #0: ffff8880b873e758 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x2a/0x140 kernel/sched/core.c:598 2 locks held by kworker/u8:8/3022: #0: ffff88801ac89148 ((wq_completion)events_unbound){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:3204 [inline] #0: ffff88801ac89148 ((wq_completion)events_unbound){+.+.}-{0:0}, at: process_scheduled_works+0x93b/0x1840 kernel/workqueue.c:3310 #1: ffffc9000b91fd00 ((reaper_work).work){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:3205 [inline] #1: ffffc9000b91fd00 ((reaper_work).work){+.+.}-{0:0}, at: process_scheduled_works+0x976/0x1840 kernel/workqueue.c:3310 3 locks held by udevd/5195: 2 locks held by getty/5578: #0: ffff888031f7f0a0 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x25/0x70 drivers/tty/tty_ldisc.c:243 #1: ffffc9000332b2f0 (&ldata->atomic_read_lock){+.+.}-{4:4}, at: n_tty_read+0x6a6/0x1e00 drivers/tty/n_tty.c:2211 1 lock held by syz.1.394/9547: #0: ffff88802a4c0420 (sb_writers#24){.+.+}-{0:0}, at: file_start_write include/linux/fs.h:2964 [inline] #0: ffff88802a4c0420 (sb_writers#24){.+.+}-{0:0}, at: vfs_writev+0x2d1/0xba0 fs/read_write.c:1048 2 locks held by syz.1.394/9615: #0: ffff88802a4c0420 (sb_writers#24){.+.+}-{0:0}, at: file_start_write include/linux/fs.h:2964 [inline] #0: ffff88802a4c0420 (sb_writers#24){.+.+}-{0:0}, at: vfs_fallocate+0x4fe/0x6e0 fs/open.c:326 #1: ffff888058d8d3c8 (&sb->s_type->i_mutex_key#30){++++}-{4:4}, at: inode_lock include/linux/fs.h:818 [inline] #1: ffff888058d8d3c8 (&sb->s_type->i_mutex_key#30){++++}-{4:4}, at: bch2_fallocate_dispatch+0x1e2/0x540 fs/bcachefs/fs-io.c:771 4 locks held by bch-reclaim/loo/9592: #0: ffff88804becb0a8 (&j->reclaim_lock){+.+.}-{4:4}, at: bch2_journal_reclaim_thread+0x167/0x560 fs/bcachefs/journal_reclaim.c:739 #1: ffff88804be84398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: srcu_lock_acquire include/linux/srcu.h:158 [inline] #1: ffff88804be84398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: srcu_read_lock include/linux/srcu.h:249 [inline] #1: ffff88804be84398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: __bch2_trans_get+0x7e1/0xd30 fs/bcachefs/btree_iter.c:3228 #2: ffff88804be84740 (&wb->flushing.lock){+.+.}-{4:4}, at: btree_write_buffer_flush_seq+0x1b19/0x1cc0 fs/bcachefs/btree_write_buffer.c:516 #3: ffff88804bea66d0 (&c->gc_lock){++++}-{4:4}, at: bch2_btree_update_start+0x682/0x14e0 fs/bcachefs/btree_update_interior.c:1197 2 locks held by kworker/u8:10/10030: #0: ffff88801ac89148 ((wq_completion)events_unbound){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:3204 [inline] #0: ffff88801ac89148 ((wq_completion)events_unbound){+.+.}-{0:0}, at: process_scheduled_works+0x93b/0x1840 kernel/workqueue.c:3310 #1: ffffc9000ae87d00 (connector_reaper_work){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:3205 [inline] #1: ffffc9000ae87d00 (connector_reaper_work){+.+.}-{0:0}, at: process_scheduled_works+0x976/0x1840 kernel/workqueue.c:3310 1 lock held by udevd/12377: 2 locks held by syz.2.607/12687: #0: ffff88802a4c00e0 (&type->s_umount_key#69){++++}-{4:4}, at: __super_lock fs/super.c:58 [inline] #0: ffff88802a4c00e0 (&type->s_umount_key#69){++++}-{4:4}, at: super_lock+0x27c/0x400 fs/super.c:120 #1: ffff88807eb4a7d0 (&bdi->wb_switch_rwsem){+.+.}-{4:4}, at: bdi_down_write_wb_switch_rwsem fs/fs-writeback.c:387 [inline] #1: ffff88807eb4a7d0 (&bdi->wb_switch_rwsem){+.+.}-{4:4}, at: sync_inodes_sb+0x26e/0xb50 fs/fs-writeback.c:2819 2 locks held by syz.8.665/14299: #0: ffff88802a4c00e0 (&type->s_umount_key#69){++++}-{4:4}, at: __super_lock fs/super.c:58 [inline] #0: ffff88802a4c00e0 (&type->s_umount_key#69){++++}-{4:4}, at: super_lock+0x27c/0x400 fs/super.c:120 #1: ffff88807eb4a7d0 (&bdi->wb_switch_rwsem){+.+.}-{4:4}, at: bdi_down_write_wb_switch_rwsem fs/fs-writeback.c:387 [inline] #1: ffff88807eb4a7d0 (&bdi->wb_switch_rwsem){+.+.}-{4:4}, at: sync_inodes_sb+0x26e/0xb50 fs/fs-writeback.c:2819 3 locks held by syz.9.712/15546: 2 locks held by syz.7.714/15506: 1 lock held by dhcpcd-run-hook/15548: ============================================= NMI backtrace for cpu 0 CPU: 0 UID: 0 PID: 30 Comm: khungtaskd Not tainted 6.13.0-rc4-syzkaller-00012-g9b2ffa6148b1 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 Call Trace: __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:234 [inline] watchdog+0xff6/0x1040 kernel/hung_task.c:397 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 Sending NMI from CPU 0 to CPUs 1: NMI backtrace for cpu 1 CPU: 1 UID: 0 PID: 14804 Comm: syz-executor Not tainted 6.13.0-rc4-syzkaller-00012-g9b2ffa6148b1 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 RIP: 0010:xas_init_marks+0x7e/0xe0 lib/xarray.c:948 Code: 31 ff e8 05 b6 e0 f5 31 ff 89 ee e8 fc b5 e0 f5 83 e3 04 74 15 85 ed 75 11 e8 ae b1 e0 f5 4c 89 f7 31 f6 e8 e4 06 00 00 eb 20 <4c> 89 f7 89 ee e8 b8 0b 00 00 bf 02 00 00 00 89 ee e8 cc b5 e0 f5 RSP: 0018:ffffc900048bf490 EFLAGS: 00000046 RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffff888030853c00 RDX: ffff888030853c00 RSI: 0000000000000002 RDI: 0000000000000000 RBP: 0000000000000002 R08: ffffffff8bbec224 R09: 1ffff1100b57509e R10: dffffc0000000000 R11: ffffed100b57509f R12: 1ffff92000917ea8 R13: ffffea0001809e40 R14: ffffc900048bf540 R15: dffffc0000000000 FS: 0000555582b6c500(0000) GS:ffff8880b8700000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000555582b8f608 CR3: 000000007cc16000 CR4: 00000000003526f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: page_cache_delete mm/filemap.c:150 [inline] __filemap_remove_folio+0x4f1/0x670 mm/filemap.c:232 filemap_remove_folio+0xe1/0x1f0 mm/filemap.c:264 truncate_inode_folio+0x5d/0x70 mm/truncate.c:162 shmem_undo_range+0x44b/0x1820 mm/shmem.c:1040 shmem_truncate_range mm/shmem.c:1156 [inline] shmem_evict_inode+0x29b/0xa80 mm/shmem.c:1284 evict+0x4e8/0x9a0 fs/inode.c:796 __dentry_kill+0x20d/0x630 fs/dcache.c:625 dput+0x19f/0x2b0 fs/dcache.c:867 __fput+0x5ba/0xa50 fs/file_table.c:458 task_work_run+0x24f/0x310 kernel/task_work.c:239 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline] exit_to_user_mode_loop kernel/entry/common.c:114 [inline] exit_to_user_mode_prepare include/linux/entry-common.h:329 [inline] __syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline] syscall_exit_to_user_mode+0x13f/0x340 kernel/entry/common.c:218 do_syscall_64+0x100/0x230 arch/x86/entry/common.c:89 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fea3678498a Code: 48 3d 00 f0 ff ff 77 48 c3 0f 1f 80 00 00 00 00 48 83 ec 18 89 7c 24 0c e8 43 91 02 00 8b 7c 24 0c 89 c2 b8 03 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 36 89 d7 89 44 24 0c e8 a3 91 02 00 8b 44 24 RSP: 002b:00007fffa7f522d0 EFLAGS: 00000293 ORIG_RAX: 0000000000000003 RAX: 0000000000000000 RBX: 0000000000000003 RCX: 00007fea3678498a RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000003 RBP: 00007fffa7f5231c R08: 0000000000000000 R09: 00007fffa7f52037 R10: 0000000000000000 R11: 0000000000000293 R12: 000000000000001c R13: 000000000006f2f7 R14: 00007fffa7f52370 R15: 0000000000000002