BUG: sleeping function called from invalid context at kernel/locking/rwsem.c:1572 in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 15, name: ksoftirqd/0 preempt_count: 100, expected: 0 RCU nest depth: 0, expected: 0 no locks held by ksoftirqd/0/15. Preemption disabled at: [] softirq_handle_begin kernel/softirq.c:416 [inline] [] handle_softirqs+0xe0/0xd58 kernel/softirq.c:554 CPU: 0 PID: 15 Comm: ksoftirqd/0 Not tainted 6.1.129-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 12/27/2024 Call trace: dump_backtrace+0x1c8/0x1f4 arch/arm64/kernel/stacktrace.c:158 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:165 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x108/0x170 lib/dump_stack.c:106 dump_stack+0x1c/0x58 lib/dump_stack.c:113 __might_resched+0x37c/0x4d8 kernel/sched/core.c:9957 __might_sleep+0x90/0xe4 kernel/sched/core.c:9886 down_write+0x28/0x88 kernel/locking/rwsem.c:1572 inode_lock include/linux/fs.h:758 [inline] jfs_fsync+0xa0/0x1c0 fs/jfs/file.c:28 vfs_fsync_range+0x168/0x188 fs/sync.c:188 generic_write_sync include/linux/fs.h:2962 [inline] dio_complete+0x5c0/0x738 fs/direct-io.c:309 dio_bio_end_aio+0x488/0x550 fs/direct-io.c:364 bio_endio+0x7c8/0x80c block/bio.c:1554 req_bio_endio block/blk-mq.c:780 [inline] blk_update_request+0x4ac/0xdf0 block/blk-mq.c:925 blk_mq_end_request+0x54/0x88 block/blk-mq.c:1050 lo_complete_rq+0x140/0x258 drivers/block/loop.c:365 blk_complete_reqs block/blk-mq.c:1130 [inline] blk_done_softirq+0x11c/0x168 block/blk-mq.c:1135 handle_softirqs+0x318/0xd58 kernel/softirq.c:578 run_ksoftirqd+0x6c/0x29c kernel/softirq.c:945 smpboot_thread_fn+0x4b0/0x96c kernel/smpboot.c:164 kthread+0x250/0x2d8 kernel/kthread.c:376 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:864 ============================= [ BUG: Invalid wait context ] 6.1.129-syzkaller #0 Tainted: G W ----------------------------- ksoftirqd/0/15 is trying to lock: ffff0000e1738580 (&sb->s_type->i_mutex_key#20){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:758 [inline] ffff0000e1738580 (&sb->s_type->i_mutex_key#20){+.+.}-{3:3}, at: jfs_fsync+0xa0/0x1c0 fs/jfs/file.c:28 other info that might help us debug this: context-{2:2} no locks held by ksoftirqd/0/15. stack backtrace: CPU: 0 PID: 15 Comm: ksoftirqd/0 Tainted: G W 6.1.129-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 12/27/2024 Call trace: dump_backtrace+0x1c8/0x1f4 arch/arm64/kernel/stacktrace.c:158 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:165 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x108/0x170 lib/dump_stack.c:106 dump_stack+0x1c/0x58 lib/dump_stack.c:113 print_lock_invalid_wait_context kernel/locking/lockdep.c:4701 [inline] check_wait_context kernel/locking/lockdep.c:4762 [inline] __lock_acquire+0x1b14/0x7680 kernel/locking/lockdep.c:4999 lock_acquire+0x26c/0x7cc kernel/locking/lockdep.c:5662 down_write+0x5c/0x88 kernel/locking/rwsem.c:1573 inode_lock include/linux/fs.h:758 [inline] jfs_fsync+0xa0/0x1c0 fs/jfs/file.c:28 vfs_fsync_range+0x168/0x188 fs/sync.c:188 generic_write_sync include/linux/fs.h:2962 [inline] dio_complete+0x5c0/0x738 fs/direct-io.c:309 dio_bio_end_aio+0x488/0x550 fs/direct-io.c:364 bio_endio+0x7c8/0x80c block/bio.c:1554 req_bio_endio block/blk-mq.c:780 [inline] blk_update_request+0x4ac/0xdf0 block/blk-mq.c:925 blk_mq_end_request+0x54/0x88 block/blk-mq.c:1050 lo_complete_rq+0x140/0x258 drivers/block/loop.c:365 blk_complete_reqs block/blk-mq.c:1130 [inline] blk_done_softirq+0x11c/0x168 block/blk-mq.c:1135 handle_softirqs+0x318/0xd58 kernel/softirq.c:578 run_ksoftirqd+0x6c/0x29c kernel/softirq.c:945 smpboot_thread_fn+0x4b0/0x96c kernel/smpboot.c:164 kthread+0x250/0x2d8 kernel/kthread.c:376 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:864