loop3: rw=1, sector=376, nr_sectors = 8 limit=64 gfs2: fsid=syz:syz.0: Error 10 writing to journal, jid=0 syz.3.126: attempt to access beyond end of device loop3: rw=1, sector=320, nr_sectors = 8 limit=64 gfs2: fsid=syz:syz.0: fatal: I/O error(s) gfs2: fsid=syz:syz.0: about to withdraw this file system BUG: sleeping function called from invalid context at kernel/sched/completion.c:101 in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 5448, name: syz.3.126 preempt_count: 1, expected: 0 RCU nest depth: 0, expected: 0 3 locks held by syz.3.126/5448: #0: ffff888056d29058 (&sdp->sd_log_flush_lock){++++}-{3:3}, at: gfs2_log_flush+0xd9/0x24e0 fs/gfs2/log.c:1043 #1: ffff888056d28e80 (&sdp->sd_log_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:351 [inline] #1: ffff888056d28e80 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_log_lock fs/gfs2/log.h:32 [inline] #1: ffff888056d28e80 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_flush_revokes+0x4e/0x80 fs/gfs2/log.c:814 #2: ffff888056d29248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: signal_our_withdraw fs/gfs2/util.c:155 [inline] #2: ffff888056d29248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: gfs2_withdraw+0x5d0/0x1780 fs/gfs2/util.c:354 Preemption disabled at: [<0000000000000000>] 0x0 CPU: 1 PID: 5448 Comm: syz.3.126 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/18/2025 Call Trace: dump_stack_lvl+0x168/0x22e lib/dump_stack.c:106 __might_resched+0x48d/0x610 kernel/sched/core.c:9966 __wait_for_common kernel/sched/completion.c:101 [inline] wait_for_common kernel/sched/completion.c:117 [inline] wait_for_completion+0x8e/0x590 kernel/sched/completion.c:138 kthread_stop+0x197/0x650 kernel/kthread.c:711 signal_our_withdraw fs/gfs2/util.c:159 [inline] gfs2_withdraw+0x643/0x1780 fs/gfs2/util.c:354 gfs2_ail1_empty+0x7be/0x850 fs/gfs2/log.c:377 gfs2_flush_revokes+0x58/0x80 fs/gfs2/log.c:815 revoke_lo_before_commit+0x28/0x5f0 fs/gfs2/lops.c:869 lops_before_commit fs/gfs2/lops.h:40 [inline] gfs2_log_flush+0xb83/0x24e0 fs/gfs2/log.c:1102 gfs2_write_inode+0x23b/0x3d0 fs/gfs2/super.c:453 write_inode fs/fs-writeback.c:1460 [inline] __writeback_single_inode+0x75b/0x1160 fs/fs-writeback.c:1677 writeback_single_inode+0x221/0x8b0 fs/fs-writeback.c:1733 sync_inode_metadata+0xb6/0x110 fs/fs-writeback.c:2790 gfs2_fsync+0x1b2/0x340 fs/gfs2/file.c:758 vfs_fsync_range fs/sync.c:188 [inline] vfs_fsync fs/sync.c:202 [inline] do_fsync fs/sync.c:212 [inline] __do_sys_fdatasync fs/sync.c:225 [inline] __se_sys_fdatasync fs/sync.c:223 [inline] __x64_sys_fdatasync+0xb5/0x110 fs/sync.c:223 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7effcd78eec9 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007effce6a4038 EFLAGS: 00000246 ORIG_RAX: 000000000000004b RAX: ffffffffffffffda RBX: 00007effcd9e5fa0 RCX: 00007effcd78eec9 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000006 RBP: 00007effcd811f91 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007effcd9e6038 R14: 00007effcd9e5fa0 R15: 00007ffec4ac92c8 BUG: scheduling while atomic: syz.3.126/5448/0x00000002 3 locks held by syz.3.126/5448: #0: ffff888056d29058 (&sdp->sd_log_flush_lock){++++}-{3:3}, at: gfs2_log_flush+0xd9/0x24e0 fs/gfs2/log.c:1043 #1: ffff888056d28e80 (&sdp->sd_log_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:351 [inline] #1: ffff888056d28e80 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_log_lock fs/gfs2/log.h:32 [inline] #1: ffff888056d28e80 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_flush_revokes+0x4e/0x80 fs/gfs2/log.c:814 #2: ffff888056d29248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: signal_our_withdraw fs/gfs2/util.c:155 [inline] #2: ffff888056d29248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: gfs2_withdraw+0x5d0/0x1780 fs/gfs2/util.c:354 Modules linked in: Preemption disabled at: [<0000000000000000>] 0x0