INFO: task syz.1.138:6901 blocked for more than 143 seconds. Not tainted 6.12.0-syzkaller-11677-g2ba9f676d0a2 #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. task:syz.1.138 state:D stack:27360 pid:6901 tgid:6824 ppid:5820 flags:0x00000006 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 schedule_preempt_disabled+0x13/0x30 kernel/sched/core.c:6905 rwsem_down_write_slowpath+0xeee/0x13b0 kernel/locking/rwsem.c:1176 __down_write_common kernel/locking/rwsem.c:1304 [inline] __down_write kernel/locking/rwsem.c:1313 [inline] down_write+0x1d7/0x220 kernel/locking/rwsem.c:1578 inode_lock include/linux/fs.h:818 [inline] do_lock_mount+0x112/0x3a0 fs/namespace.c:2607 lock_mount fs/namespace.c:2649 [inline] do_loopback+0x2be/0x520 fs/namespace.c:2772 do_mount fs/namespace.c:3847 [inline] __do_sys_mount fs/namespace.c:4057 [inline] __se_sys_mount+0x2d6/0x3c0 fs/namespace.c:4034 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:0x7fabaa780849 RSP: 002b:00007fabab59e058 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 00007fabaa946080 RCX: 00007fabaa780849 RDX: 0000000000000000 RSI: 0000000020000340 RDI: 0000000020000380 RBP: 00007fabaa7f3986 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000001000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000001 R14: 00007fabaa946080 R15: 00007ffd73dc35d8 INFO: task syz.1.138:6903 blocked for more than 144 seconds. Not tainted 6.12.0-syzkaller-11677-g2ba9f676d0a2 #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. task:syz.1.138 state:D stack:26296 pid:6903 tgid:6824 ppid:5820 flags:0x00000004 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 schedule_preempt_disabled+0x13/0x30 kernel/sched/core.c:6905 rwsem_down_write_slowpath+0xeee/0x13b0 kernel/locking/rwsem.c:1176 __down_write_common kernel/locking/rwsem.c:1304 [inline] __down_write kernel/locking/rwsem.c:1313 [inline] down_write+0x1d7/0x220 kernel/locking/rwsem.c:1578 inode_lock include/linux/fs.h:818 [inline] process_measurement+0x439/0x1fb0 security/integrity/ima/ima_main.c:250 ima_file_check+0xd9/0x120 security/integrity/ima/ima_main.c:572 security_file_post_open+0xb9/0x280 security/security.c:3121 do_open fs/namei.c:3830 [inline] path_openat+0x2ccd/0x3590 fs/namei.c:3987 do_filp_open+0x27f/0x4e0 fs/namei.c:4014 do_sys_openat2+0x13e/0x1d0 fs/open.c:1402 do_sys_open fs/open.c:1417 [inline] __do_sys_open fs/open.c:1425 [inline] __se_sys_open fs/open.c:1421 [inline] __x64_sys_open+0x225/0x270 fs/open.c:1421 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:0x7fabaa780849 RSP: 002b:00007fabab57d058 EFLAGS: 00000246 ORIG_RAX: 0000000000000002 RAX: ffffffffffffffda RBX: 00007fabaa946160 RCX: 00007fabaa780849 RDX: 0000000000000000 RSI: 0000000000143142 RDI: 0000000020000100 RBP: 00007fabaa7f3986 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000001 R14: 00007fabaa946160 R15: 00007ffd73dc35d8 INFO: task syz.1.138:6904 blocked for more than 144 seconds. Not tainted 6.12.0-syzkaller-11677-g2ba9f676d0a2 #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. task:syz.1.138 state:D stack:23840 pid:6904 tgid:6824 ppid:5820 flags:0x00000004 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 schedule_preempt_disabled+0x13/0x30 kernel/sched/core.c:6905 rwsem_down_write_slowpath+0xeee/0x13b0 kernel/locking/rwsem.c:1176 __down_write_common kernel/locking/rwsem.c:1304 [inline] __down_write kernel/locking/rwsem.c:1313 [inline] down_write+0x1d7/0x220 kernel/locking/rwsem.c:1578 inode_lock include/linux/fs.h:818 [inline] bch2_write_iter+0x134/0x2440 fs/bcachefs/fs-io-buffered.c:1040 new_sync_write fs/read_write.c:586 [inline] vfs_write+0xaeb/0xd30 fs/read_write.c:679 ksys_write+0x18f/0x2b0 fs/read_write.c:731 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:0x7fabaa780849 RSP: 002b:00007fabab55c058 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 00007fabaa946240 RCX: 00007fabaa780849 RDX: 0000000000000028 RSI: 0000000020000040 RDI: 0000000000000008 RBP: 00007fabaa7f3986 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 00007fabaa946240 R15: 00007ffd73dc35d8 Showing all locks held in the system: 1 lock held by pool_workqueue_/3: 2 locks held by kworker/u8:0/11: 1 lock held by khungtaskd/30: #0: ffffffff8e93c5a0 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:337 [inline] #0: ffffffff8e93c5a0 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline] #0: ffffffff8e93c5a0 (rcu_read_lock){....}-{1:3}, at: debug_show_all_locks+0x55/0x2a0 kernel/locking/lockdep.c:6744 2 locks held by getty/5579: #0: ffff88814dad90a0 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x25/0x70 drivers/tty/tty_ldisc.c:243 #1: ffffc9000330b2f0 (&ldata->atomic_read_lock){+.+.}-{4:4}, at: n_tty_read+0x6a6/0x1e00 drivers/tty/n_tty.c:2211 5 locks held by syz.1.138/6825: #0: ffff888027d96420 (sb_writers#23){.+.+}-{0:0}, at: mnt_want_write+0x3f/0x90 fs/namespace.c:515 #1: ffff8880520297c8 (&sb->s_type->i_mutex_key#37){++++}-{4:4}, at: inode_lock include/linux/fs.h:818 [inline] #1: ffff8880520297c8 (&sb->s_type->i_mutex_key#37){++++}-{4:4}, at: do_truncate+0x20c/0x310 fs/open.c:63 #2: ffff888053600a38 (&c->snapshot_create_lock){.+.+}-{4:4}, at: bch2_truncate+0x166/0x2d0 fs/bcachefs/io_misc.c:292 #3: ffff888053604398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: srcu_lock_acquire include/linux/srcu.h:158 [inline] #3: ffff888053604398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: srcu_read_lock include/linux/srcu.h:249 [inline] #3: ffff888053604398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: __bch2_trans_get+0x7e1/0xd30 fs/bcachefs/btree_iter.c:3228 #4: ffff8880536266d0 (&c->gc_lock){++++}-{4:4}, at: bch2_btree_update_start+0x682/0x14e0 fs/bcachefs/btree_update_interior.c:1197 1 lock held by syz.1.138/6901: #0: ffff8880520297c8 (&sb->s_type->i_mutex_key#37){++++}-{4:4}, at: inode_lock include/linux/fs.h:818 [inline] #0: ffff8880520297c8 (&sb->s_type->i_mutex_key#37){++++}-{4:4}, at: do_lock_mount+0x112/0x3a0 fs/namespace.c:2607 1 lock held by syz.1.138/6903: #0: ffff8880520297c8 (&sb->s_type->i_mutex_key#37){++++}-{4:4}, at: inode_lock include/linux/fs.h:818 [inline] #0: ffff8880520297c8 (&sb->s_type->i_mutex_key#37){++++}-{4:4}, at: process_measurement+0x439/0x1fb0 security/integrity/ima/ima_main.c:250 3 locks held by syz.1.138/6904: #0: ffff888032e647f8 (&f->f_pos_lock){+.+.}-{4:4}, at: fdget_pos+0x254/0x320 fs/file.c:1191 #1: ffff888027d96420 (sb_writers#23){.+.+}-{0:0}, at: file_start_write include/linux/fs.h:2964 [inline] #1: ffff888027d96420 (sb_writers#23){.+.+}-{0:0}, at: vfs_write+0x225/0xd30 fs/read_write.c:675 #2: ffff8880520297c8 (&sb->s_type->i_mutex_key#37){++++}-{4:4}, at: inode_lock include/linux/fs.h:818 [inline] #2: ffff8880520297c8 (&sb->s_type->i_mutex_key#37){++++}-{4:4}, at: bch2_write_iter+0x134/0x2440 fs/bcachefs/fs-io-buffered.c:1040 4 locks held by bch-reclaim/loo/6849: #0: ffff88805364b0a8 (&j->reclaim_lock){+.+.}-{4:4}, at: bch2_journal_reclaim_thread+0x167/0x560 fs/bcachefs/journal_reclaim.c:739 #1: ffff888053604398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: srcu_lock_acquire include/linux/srcu.h:158 [inline] #1: ffff888053604398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: srcu_read_lock include/linux/srcu.h:249 [inline] #1: ffff888053604398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: __bch2_trans_get+0x7e1/0xd30 fs/bcachefs/btree_iter.c:3228 #2: ffff888053604740 (&wb->flushing.lock){+.+.}-{4:4}, at: btree_write_buffer_flush_seq+0x1b19/0x1cc0 fs/bcachefs/btree_write_buffer.c:516 #3: ffff8880536266d0 (&c->gc_lock){++++}-{4:4}, at: bch2_btree_update_start+0x682/0x14e0 fs/bcachefs/btree_update_interior.c:1197 3 locks held by syz.3.391/8983: #0: ffff88804d5800e0 (&type->s_umount_key#73){++++}-{4:4}, at: __super_lock fs/super.c:58 [inline] #0: ffff88804d5800e0 (&type->s_umount_key#73){++++}-{4:4}, at: super_lock+0x27c/0x400 fs/super.c:120 #1: ffff888060684398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: srcu_lock_acquire include/linux/srcu.h:158 [inline] #1: ffff888060684398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: srcu_read_lock include/linux/srcu.h:249 [inline] #1: ffff888060684398 (&c->btree_trans_barrier){.+.+}-{0:0}, at: __bch2_trans_get+0x7e1/0xd30 fs/bcachefs/btree_iter.c:3228 #2: ffff8880606a66d0 (&c->gc_lock){++++}-{4:4}, at: bch2_btree_update_start+0x682/0x14e0 fs/bcachefs/btree_update_interior.c:1197 2 locks held by dhcpcd/9305: #0: ffff88806a5fe258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1617 [inline] #0: ffff88806a5fe258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_do_bind+0x32/0xcb0 net/packet/af_packet.c:3267 #1: ffffffff8e941b38 (rcu_state.exp_mutex){+.+.}-{4:4}, at: exp_funnel_lock kernel/rcu/tree_exp.h:329 [inline] #1: ffffffff8e941b38 (rcu_state.exp_mutex){+.+.}-{4:4}, at: synchronize_rcu_expedited+0x451/0x830 kernel/rcu/tree_exp.h:976 1 lock held by dhcpcd/9306: #0: ffff888034a06258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1617 [inline] #0: ffff888034a06258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_do_bind+0x32/0xcb0 net/packet/af_packet.c:3267 1 lock held by dhcpcd/9307: #0: ffff88807c9ea258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1617 [inline] #0: ffff88807c9ea258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_do_bind+0x32/0xcb0 net/packet/af_packet.c:3267 1 lock held by dhcpcd/9308: #0: ffff88807be28258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1617 [inline] #0: ffff88807be28258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_do_bind+0x32/0xcb0 net/packet/af_packet.c:3267 1 lock held by dhcpcd/9309: #0: ffff88803501c258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1617 [inline] #0: ffff88803501c258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_do_bind+0x32/0xcb0 net/packet/af_packet.c:3267 1 lock held by dhcpcd/9310: #0: ffff88806a212258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1617 [inline] #0: ffff88806a212258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_do_bind+0x32/0xcb0 net/packet/af_packet.c:3267 1 lock held by dhcpcd/9315: #0: ffff888031940258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1617 [inline] #0: ffff888031940258 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_do_bind+0x32/0xcb0 net/packet/af_packet.c:3267 ============================================= NMI backtrace for cpu 0 CPU: 0 UID: 0 PID: 30 Comm: khungtaskd Not tainted 6.12.0-syzkaller-11677-g2ba9f676d0a2 #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: 5887 Comm: kworker/u8:8 Not tainted 6.12.0-syzkaller-11677-g2ba9f676d0a2 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 Workqueue: events_unbound nsim_dev_trap_report_work RIP: 0010:psi_flags_change kernel/sched/psi.c:887 [inline] RIP: 0010:psi_task_switch+0x309/0x7a0 kernel/sched/psi.c:969 Code: 44 0f b7 ed 49 8d b9 e0 12 00 00 48 89 fe 48 c1 ee 03 42 0f b6 04 16 84 c0 48 89 7c 24 10 48 89 34 24 0f 85 f1 02 00 00 8b 2f <44> 85 ed 75 0a 89 e8 44 21 f8 44 39 f8 74 0d 80 3d 39 53 ad 0e 00 RSP: 0018:ffffc9000419f730 EFLAGS: 00000046 RAX: 0000000000000000 RBX: ffffffff8e802cc0 RCX: 0000000080000002 RDX: 0000000000000000 RSI: 1ffff11006b9bd9c RDI: ffff888035cdece0 RBP: 0000000000000014 R08: ffff888035cddfc8 R09: ffff888035cdda00 R10: dffffc0000000000 R11: ffffed1006b9bb41 R12: 0000000000000001 R13: 0000000000000000 R14: 1ffff11006b9bbf9 R15: 0000000000000010 FS: 0000000000000000(0000) GS:ffff8880b8700000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 000055c2cb58ea18 CR3: 000000000e738000 CR4: 00000000003526f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: psi_sched_switch kernel/sched/stats.h:216 [inline] __schedule+0x21ca/0x4be0 kernel/sched/core.c:6751 preempt_schedule_common+0x84/0xd0 kernel/sched/core.c:6935 preempt_schedule+0xe1/0xf0 kernel/sched/core.c:6959 preempt_schedule_thunk+0x1a/0x30 arch/x86/entry/thunk.S:12 __raw_spin_unlock include/linux/spinlock_api_smp.h:143 [inline] _raw_spin_unlock+0x3e/0x50 kernel/locking/spinlock.c:186 spin_unlock include/linux/spinlock.h:391 [inline] nsim_dev_trap_report drivers/net/netdevsim/dev.c:823 [inline] nsim_dev_trap_report_work+0xa5d/0xb50 drivers/net/netdevsim/dev.c:851 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