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: 211d, last: 32d
▶ ▼ 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 397d 397d 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 syz, C error 31 32d 615d 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 syz, C error done 182 1055d 1176d 25/30 fixed on 2024/03/20 11:33
upstream BUG: sleeping function called from invalid context in gfs2_withdraw (2) gfs2 5 24 362d 441d 0/30 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 330d 486d 0/2 auto-obsoleted due to no activity on 2026/04/13 03:54

Sample crash report:
loop0: detected capacity change from 32768 to 0
syz.0.4841: attempt to access beyond end of device
loop0: rw=1, sector=2056, nr_sectors = 8 limit=0
gfs2: fsid=syz:syz.0: Error 10 writing to journal, jid=0
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: 23604, name: syz.0.4841
preempt_count: 1, expected: 0
RCU nest depth: 0, expected: 0
5 locks held by syz.0.4841/23604:
 #0: ffff88807851e418 (sb_writers#38){.+.+}-{0:0}, at: mnt_want_write_file+0x63/0x200 fs/namespace.c:456
 #1: ffff88804b370ed0 (&sb->s_type->i_mutex_key
#40
){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:804 [inline]
){+.+.}-{3:3}, at: vfs_fileattr_set+0x154/0xb10 fs/ioctl.c:682
 #2: ffff888045149060 (&sdp->sd_log_flush_lock){++++}-{3:3}, at: gfs2_log_flush+0x27/0x50 fs/gfs2/log.c:1179
 #3: ffff888045148e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:351 [inline]
 #3: ffff888045148e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_log_lock fs/gfs2/log.h:32 [inline]
 #3: ffff888045148e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_flush_revokes+0x52/0x80 fs/gfs2/log.c:815
 #4: ffff888045149248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: signal_our_withdraw fs/gfs2/util.c:152 [inline]
 #4: ffff888045149248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: gfs2_withdraw+0x429/0x1400 fs/gfs2/util.c:333
Preemption disabled at:
[<0000000000000000>] 0x0
CPU: 1 PID: 23604 Comm: syz.0.4841 Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
Call Trace:
 <TASK>
 dump_stack_lvl+0x18c/0x250 lib/dump_stack.c:106
 __might_resched+0x48d/0x5f0 kernel/sched/core.c:10264
 signal_our_withdraw fs/gfs2/util.c:157 [inline]
 gfs2_withdraw+0x477/0x1400 fs/gfs2/util.c:333
 gfs2_ail1_empty+0x7d1/0x860 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+0xbe7/0x24d0 fs/gfs2/log.c:1103
 gfs2_log_flush+0x34/0x50 fs/gfs2/log.c:1180
 do_gfs2_set_flags fs/gfs2/file.c:245 [inline]
 gfs2_fileattr_set+0x5d9/0x970 fs/gfs2/file.c:311
 vfs_fileattr_set+0x85d/0xb10 fs/ioctl.c:697
 ioctl_setflags fs/ioctl.c:729 [inline]
 do_vfs_ioctl+0x1442/0x1cc0 fs/ioctl.c:840
 __do_sys_ioctl fs/ioctl.c:869 [inline]
 __se_sys_ioctl+0x83/0x170 fs/ioctl.c:857
 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:0x7f274359f559
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:00007f2744547028 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007f2743825fa0 RCX: 00007f274359f559
RDX: 0000200000013880 RSI: 0000000040086602 RDI: 0000000000000004
RBP: 00007f2743636b20 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f2743826038 R14: 00007f2743825fa0 R15: 00007ffd98247de8
 </TASK>
BUG: scheduling while atomic: syz.0.4841/23604/0x00000002
5 locks held by syz.0.4841/23604:
 #0: ffff88807851e418 (sb_writers#38){.+.+}-{0:0}, at: mnt_want_write_file+0x63/0x200 fs/namespace.c:456
 #1: ffff88804b370ed0 (&sb->s_type->i_mutex_key#40){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:804 [inline]
 #1: ffff88804b370ed0 (&sb->s_type->i_mutex_key#40){+.+.}-{3:3}, at: vfs_fileattr_set+0x154/0xb10 fs/ioctl.c:682
 #2: ffff888045149060 (&sdp->sd_log_flush_lock){++++}-{3:3}, at: gfs2_log_flush+0x27/0x50 fs/gfs2/log.c:1179
 #3: ffff888045148e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:351 [inline]
 #3: ffff888045148e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_log_lock fs/gfs2/log.h:32 [inline]
 #3: ffff888045148e88 (&sdp->sd_log_lock){+.+.}-{2:2}, at: gfs2_flush_revokes+0x52/0x80 fs/gfs2/log.c:815
 #4: ffff888045149248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: signal_our_withdraw fs/gfs2/util.c:152 [inline]
 #4: ffff888045149248 (&sdp->sd_freeze_mutex){+.+.}-{3:3}, at: gfs2_withdraw+0x429/0x1400 fs/gfs2/util.c:333
Modules linked in:
Preemption disabled at:
[<0000000000000000>] 0x0

Crashes (18):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/10/28 01:54 linux-6.6.y 0aebf2870d53 96923c60 .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/10/22 21:32 linux-6.6.y 0aebf2870d53 b55fad29 .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/09/13 06:39 linux-6.6.y 8b73de7da85f 70a60e12 .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/09/11 19:37 linux-6.6.y 8b73de7da85f b6a5eeb7 .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/09/09 23:41 linux-6.6.y 8b73de7da85f 4e8b1cc6 .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/08/31 10:29 linux-6.6.y a4a971135a2f 2f52988a .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/07/22 09:44 linux-6.6.y da47cbc25466 b561ce9c .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/07/13 10:58 linux-6.6.y da47cbc25466 d78ea535 .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/07/13 10:57 linux-6.6.y da47cbc25466 d78ea535 .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/07/13 10:55 linux-6.6.y da47cbc25466 d78ea535 .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/06/25 04:17 linux-6.6.y d1cfde2d5d15 302586aa .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/06/25 04:16 linux-6.6.y d1cfde2d5d15 302586aa .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/06/25 04:12 linux-6.6.y d1cfde2d5d15 302586aa .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/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.