syzbot


BUG: sleeping function called from invalid context in gfs2_withdraw (2)

Status: upstream: reported on 2026/05/01 12:40
Reported-by: syzbot+8cbe100e78641dc50b4c@syzkaller.appspotmail.com
First crash: 39d, last: 1d19h
Similar bugs (5)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-5.15 BUG: sleeping function called from invalid context in gfs2_withdraw 5 1 225d 225d 0/3 auto-obsoleted due to no activity on 2026/02/04 10:36
linux-6.1 BUG: sleeping function called from invalid context in gfs2_withdraw origin:upstream 5 C error 24 157d 442d 0/3 upstream: reported C repro on 2025/03/23 18:44
upstream BUG: sleeping function called from invalid context in gfs2_withdraw gfs2 5 C error done 182 882d 1003d 25/29 fixed on 2024/03/20 11:33
upstream BUG: sleeping function called from invalid context in gfs2_withdraw (2) gfs2 5 24 189d 268d 0/29 auto-obsoleted due to no activity on 2026/02/10 02:34
linux-6.6 BUG: sleeping function called from invalid context in gfs2_withdraw 5 13 157d 313d 0/2 auto-obsoleted due to no activity on 2026/04/13 03:54

Sample crash report:
syz.0.34: attempt to access beyond end of device
loop0: 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 fs/gfs2/util.c:159
in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 5965, name: syz.0.34
preempt_count: 1, expected: 0
RCU nest depth: 0, expected: 0
5 locks held by syz.0.34/5965:
 #0: ffff8880220d6418 (sb_writers#21){.+.+}-{0:0}, at: vfs_write+0x21b/0x990 fs/read_write.c:580
 #1: ffff88805d269c40 (&sb->s_type->i_mutex_key#26){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:804 [inline]
 #1: ffff88805d269c40 (&sb->s_type->i_mutex_key#26){+.+.}-{3:3}, at: gfs2_file_write_iter+0x352/0xe90 fs/gfs2/file.c:1115
 #2: ffff88807e1e5060 (&sdp->sd_log_flush_lock){++++}-{3:3}, at: gfs2_log_flush+0x27/0x50 fs/gfs2/log.c:1179
 #3: ffff88807e1e4e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:351 [inline]
 #3: ffff88807e1e4e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_log_lock fs/gfs2/log.h:32 [inline]
 #3: ffff88807e1e4e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_flush_revokes+0x52/0x80 fs/gfs2/log.c:815
 #4: ffff88807e1e5248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: signal_our_withdraw fs/gfs2/util.c:152 [inline]
 #4: ffff88807e1e5248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: gfs2_withdraw+0x43a/0x13d0 fs/gfs2/util.c:333
Preemption disabled at:
[<0000000000000000>] 0x0
CPU: 0 PID: 5965 Comm: syz.0.34 Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/18/2026
Call Trace:
 <TASK>
 dump_stack_lvl+0x18c/0x250 lib/dump_stack.c:106
 __might_resched+0x4ad/0x630 kernel/sched/core.c:10211
 signal_our_withdraw fs/gfs2/util.c:157 [inline]
 gfs2_withdraw+0x488/0x13d0 fs/gfs2/util.c:333
 gfs2_ail1_empty+0x7be/0x850 fs/gfs2/log.c:377
 gfs2_flush_revokes+0x5c/0x80 fs/gfs2/log.c:816
 revoke_lo_before_commit+0x2c/0x5f0 fs/gfs2/lops.c:867
 lops_before_commit fs/gfs2/lops.h:42 [inline]
 __gfs2_log_flush+0xbe1/0x2500 fs/gfs2/log.c:1103
 gfs2_log_flush+0x34/0x50 fs/gfs2/log.c:1180
 gfs2_write_inode+0x23f/0x3d0 fs/gfs2/super.c:457
 write_inode fs/fs-writeback.c:1483 [inline]
 __writeback_single_inode+0x705/0xec0 fs/fs-writeback.c:1700
 writeback_single_inode+0x21f/0x760 fs/fs-writeback.c:1756
 sync_inode_metadata+0xe0/0x140 fs/fs-writeback.c:2828
 gfs2_fsync+0x1b6/0x350 fs/gfs2/file.c:762
 generic_write_sync include/linux/fs.h:2651 [inline]
 gfs2_file_write_iter+0xcea/0xe90 fs/gfs2/file.c:1160
 call_write_iter include/linux/fs.h:2018 [inline]
 new_sync_write fs/read_write.c:491 [inline]
 vfs_write+0x46c/0x990 fs/read_write.c:584
 ksys_pwrite64 fs/read_write.c:699 [inline]
 __do_sys_pwrite64 fs/read_write.c:709 [inline]
 __se_sys_pwrite64 fs/read_write.c:706 [inline]
 __x64_sys_pwrite64+0x19b/0x230 fs/read_write.c:706
 do_syscall_x64 arch/x86/entry/common.c:46 [inline]
 do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:76
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f71bf19ce59
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 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 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f71c00fc028 EFLAGS: 00000246 ORIG_RAX: 0000000000000012
RAX: ffffffffffffffda RBX: 00007f71bf415fa0 RCX: 00007f71bf19ce59
RDX: 000000000000fdef RSI: 0000200000000140 RDI: 0000000000000005
RBP: 00007f71bf232d6f R08: 0000000000000000 R09: 0000000000000000
R10: 000000000000fecc R11: 0000000000000246 R12: 0000000000000000
R13: 00007f71bf416038 R14: 00007f71bf415fa0 R15: 00007ffe57542688
 </TASK>
BUG: scheduling while atomic: syz.0.34/5965/0x00000002
5 locks held by syz.0.34/5965:
 #0: ffff8880220d6418 (sb_writers#21){.+.+}-{0:0}, at: vfs_write+0x21b/0x990 fs/read_write.c:580
 #1: ffff88805d269c40 (&sb->s_type->i_mutex_key#26){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:804 [inline]
 #1: ffff88805d269c40 (&sb->s_type->i_mutex_key#26){+.+.}-{3:3}, at: gfs2_file_write_iter+0x352/0xe90 fs/gfs2/file.c:1115
 #2: ffff88807e1e5060 (&sdp->sd_log_flush_lock){++++}-{3:3}, at: gfs2_log_flush+0x27/0x50 fs/gfs2/log.c:1179
 #3: ffff88807e1e4e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:351 [inline]
 #3: ffff88807e1e4e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_log_lock fs/gfs2/log.h:32 [inline]
 #3: ffff88807e1e4e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_flush_revokes+0x52/0x80 fs/gfs2/log.c:815
 #4: ffff88807e1e5248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: signal_our_withdraw fs/gfs2/util.c:152 [inline]
 #4: ffff88807e1e5248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: gfs2_withdraw+0x43a/0x13d0 fs/gfs2/util.c:333
Modules linked in:
Preemption disabled at:
[<0000000000000000>] 0x0

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/06/07 19:01 linux-6.6.y 924b4a879cbb cc095639 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan BUG: sleeping function called from invalid context in gfs2_withdraw
2026/05/14 12:09 linux-6.6.y 3b9f64db0496 6ccb967e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan BUG: sleeping function called from invalid context in gfs2_withdraw
2026/05/14 12:04 linux-6.6.y 3b9f64db0496 6ccb967e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan BUG: sleeping function called from invalid context in gfs2_withdraw
2026/05/03 14:10 linux-6.6.y 258cf62a6dfd a0d91488 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan BUG: sleeping function called from invalid context in gfs2_withdraw
2026/05/01 12:39 linux-6.6.y 258cf62a6dfd 753c55b9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan BUG: sleeping function called from invalid context in gfs2_withdraw
* Struck through repros no longer work on HEAD.