====================================================== WARNING: possible circular locking dependency detected syzkaller #0 Not tainted ------------------------------------------------------ syz.7.516/7424 is trying to acquire lock: ffff88807b374ae0 (&sdp->sd_quota_mutex){+.+.}-{3:3}, at: do_qc+0xca/0x730 fs/gfs2/quota.c:682 but task is already holding lock: ffff888077e6a780 (&ip->i_rw_mutex){++++}-{3:3}, at: sweep_bh_for_rgrps fs/gfs2/bmap.c:1529 [inline] ffff888077e6a780 (&ip->i_rw_mutex){++++}-{3:3}, at: punch_hole+0x24b8/0x3760 fs/gfs2/bmap.c:1854 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (&ip->i_rw_mutex){++++}-{3:3}: down_read+0x42/0x2d0 kernel/locking/rwsem.c:1520 __gfs2_iomap_get+0x15b/0x1400 fs/gfs2/bmap.c:862 gfs2_iomap_get+0xeb/0x170 fs/gfs2/bmap.c:1413 bh_get+0x26d/0x780 fs/gfs2/quota.c:385 qdsb_get+0x21c/0x3c0 fs/gfs2/quota.c:522 gfs2_quota_hold+0x194/0x5d0 fs/gfs2/quota.c:608 gfs2_dinode_dealloc fs/gfs2/super.c:1212 [inline] evict_unlinked_inode+0x488/0x700 fs/gfs2/super.c:1410 gfs2_evict_inode+0x6c5/0x11d0 fs/gfs2/super.c:1499 evict+0x4c9/0x8d0 fs/inode.c:705 do_unlinkat+0x388/0x580 fs/namei.c:4405 __do_sys_unlink fs/namei.c:4446 [inline] __se_sys_unlink fs/namei.c:4444 [inline] __x64_sys_unlink+0x45/0x50 fs/namei.c:4444 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> #0 (&sdp->sd_quota_mutex){+.+.}-{3:3}: check_prev_add kernel/locking/lockdep.c:3090 [inline] check_prevs_add kernel/locking/lockdep.c:3209 [inline] validate_chain kernel/locking/lockdep.c:3825 [inline] __lock_acquire+0x2d07/0x7d10 kernel/locking/lockdep.c:5049 lock_acquire+0x1bb/0x4a0 kernel/locking/lockdep.c:5662 __mutex_lock_common kernel/locking/mutex.c:603 [inline] __mutex_lock+0x12d/0xaf0 kernel/locking/mutex.c:747 do_qc+0xca/0x730 fs/gfs2/quota.c:682 gfs2_quota_change+0x2f5/0x8e0 fs/gfs2/quota.c:1295 punch_hole+0x3155/0x3760 fs/gfs2/bmap.c:1955 evict_unlinked_inode+0x1a9/0x700 fs/gfs2/super.c:1400 gfs2_evict_inode+0x6c5/0x11d0 fs/gfs2/super.c:1499 evict+0x4c9/0x8d0 fs/inode.c:705 __dentry_kill+0x431/0x650 fs/dcache.c:611 dentry_kill+0xb8/0x290 fs/dcache.c:-1 dput+0xfa/0x1d0 fs/dcache.c:918 __fput+0x5e0/0x920 fs/file_table.c:328 task_work_run+0x1d0/0x260 kernel/task_work.c:203 exit_task_work include/linux/task_work.h:39 [inline] do_exit+0x982/0x2480 kernel/exit.c:880 do_group_exit+0x217/0x2d0 kernel/exit.c:1022 get_signal+0x1272/0x1350 kernel/signal.c:2871 arch_do_signal_or_restart+0xc4/0x1350 arch/x86/kernel/signal.c:871 exit_to_user_mode_loop+0x70/0x110 kernel/entry/common.c:174 exit_to_user_mode_prepare+0xee/0x180 kernel/entry/common.c:210 irqentry_exit_to_user_mode+0x5/0x30 kernel/entry/common.c:316 exc_page_fault+0x88/0x100 arch/x86/mm/fault.c:1485 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:608 other info that might help us debug this: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&ip->i_rw_mutex); lock(&sdp->sd_quota_mutex); lock(&ip->i_rw_mutex); lock(&sdp->sd_quota_mutex); *** DEADLOCK *** 3 locks held by syz.7.516/7424: #0: ffff888029d64650 (sb_internal#7){.+.+}-{0:0}, at: gfs2_trans_begin+0x6b/0xe0 fs/gfs2/trans.c:118 #1: ffff88807b375058 (&sdp->sd_log_flush_lock){.+.+}-{3:3}, at: __gfs2_trans_begin+0x513/0x890 fs/gfs2/trans.c:87 #2: ffff888077e6a780 (&ip->i_rw_mutex){++++}-{3:3}, at: sweep_bh_for_rgrps fs/gfs2/bmap.c:1529 [inline] #2: ffff888077e6a780 (&ip->i_rw_mutex){++++}-{3:3}, at: punch_hole+0x24b8/0x3760 fs/gfs2/bmap.c:1854 stack backtrace: CPU: 1 PID: 7424 Comm: syz.7.516 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/18/2026 Call Trace: dump_stack_lvl+0x188/0x24e lib/dump_stack.c:106 check_noncircular+0x296/0x330 kernel/locking/lockdep.c:2170 check_prev_add kernel/locking/lockdep.c:3090 [inline] check_prevs_add kernel/locking/lockdep.c:3209 [inline] validate_chain kernel/locking/lockdep.c:3825 [inline] __lock_acquire+0x2d07/0x7d10 kernel/locking/lockdep.c:5049 lock_acquire+0x1bb/0x4a0 kernel/locking/lockdep.c:5662 __mutex_lock_common kernel/locking/mutex.c:603 [inline] __mutex_lock+0x12d/0xaf0 kernel/locking/mutex.c:747 do_qc+0xca/0x730 fs/gfs2/quota.c:682 gfs2_quota_change+0x2f5/0x8e0 fs/gfs2/quota.c:1295 punch_hole+0x3155/0x3760 fs/gfs2/bmap.c:1955 evict_unlinked_inode+0x1a9/0x700 fs/gfs2/super.c:1400 gfs2_evict_inode+0x6c5/0x11d0 fs/gfs2/super.c:1499 evict+0x4c9/0x8d0 fs/inode.c:705 __dentry_kill+0x431/0x650 fs/dcache.c:611 dentry_kill+0xb8/0x290 fs/dcache.c:-1 dput+0xfa/0x1d0 fs/dcache.c:918 __fput+0x5e0/0x920 fs/file_table.c:328 task_work_run+0x1d0/0x260 kernel/task_work.c:203 exit_task_work include/linux/task_work.h:39 [inline] do_exit+0x982/0x2480 kernel/exit.c:880 do_group_exit+0x217/0x2d0 kernel/exit.c:1022 get_signal+0x1272/0x1350 kernel/signal.c:2871 arch_do_signal_or_restart+0xc4/0x1350 arch/x86/kernel/signal.c:871 exit_to_user_mode_loop+0x70/0x110 kernel/entry/common.c:174 exit_to_user_mode_prepare+0xee/0x180 kernel/entry/common.c:210 irqentry_exit_to_user_mode+0x5/0x30 kernel/entry/common.c:316 exc_page_fault+0x88/0x100 arch/x86/mm/fault.c:1485 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:608 RIP: 0033:0x7fe6a0b9c821 Code: Unable to access opcode bytes at 0x7fe6a0b9c7f7. RSP: 002b:00000000fffffeb0 EFLAGS: 00010217 RAX: 0000000000000000 RBX: 00007fe6a0e15fa0 RCX: 00007fe6a0b9c819 RDX: 0000000000000000 RSI: 00000000fffffeb0 RDI: 0000000002000400 RBP: 00007fe6a0c32c91 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000206 R12: 0000000000000000 R13: 00007fe6a0e16038 R14: 00007fe6a0e15fa0 R15: 00007ffd9219fca8