====================================================== WARNING: possible circular locking dependency detected syzkaller #0 Not tainted ------------------------------------------------------ syz-executor/5774 is trying to acquire lock: ffff88805ed35380 (&rl->lock){++++}-{3:3}, at: ntfs_read_block fs/ntfs/aops.c:248 [inline] ffff88805ed35380 (&rl->lock){++++}-{3:3}, at: ntfs_read_folio+0x145d/0x2990 fs/ntfs/aops.c:436 but task is already holding lock: ffff88805ed34390 (&ni->mrec_lock){+.+.}-{3:3}, at: map_mft_record+0x50/0x650 fs/ntfs/mft.c:154 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (&ni->mrec_lock){+.+.}-{3:3}: __mutex_lock_common kernel/locking/mutex.c:603 [inline] __mutex_lock+0x136/0xcc0 kernel/locking/mutex.c:747 map_mft_record+0x50/0x650 fs/ntfs/mft.c:154 ntfs_truncate+0x28a/0x28a0 fs/ntfs/inode.c:2383 ntfs_truncate_vfs fs/ntfs/inode.c:2863 [inline] ntfs_setattr+0x34a/0x430 fs/ntfs/inode.c:2915 notify_change+0xb0d/0xe10 fs/attr.c:499 do_truncate+0x1b0/0x240 fs/open.c:66 vfs_truncate+0x266/0x300 fs/open.c:112 do_sys_truncate+0xf6/0x1c0 fs/open.c:135 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 -> #0 (&rl->lock){++++}-{3:3}: check_prev_add kernel/locking/lockdep.c:3134 [inline] check_prevs_add kernel/locking/lockdep.c:3253 [inline] validate_chain kernel/locking/lockdep.c:3869 [inline] __lock_acquire+0x2df1/0x7d40 kernel/locking/lockdep.c:5137 lock_acquire+0x19e/0x420 kernel/locking/lockdep.c:5754 down_read+0x46/0x2e0 kernel/locking/rwsem.c:1520 ntfs_read_block fs/ntfs/aops.c:248 [inline] ntfs_read_folio+0x145d/0x2990 fs/ntfs/aops.c:436 filemap_read_folio+0x172/0x760 mm/filemap.c:2420 do_read_cache_folio+0x468/0x7d0 mm/filemap.c:3809 do_read_cache_page+0x32/0x250 mm/filemap.c:3875 read_mapping_page include/linux/pagemap.h:892 [inline] ntfs_map_page fs/ntfs/aops.h:75 [inline] ntfs_sync_mft_mirror+0x253/0x1ac0 fs/ntfs/mft.c:480 write_mft_record_nolock+0x1424/0x18f0 fs/ntfs/mft.c:805 write_mft_record+0x136/0x300 fs/ntfs/mft.h:95 __ntfs_write_inode+0x731/0xc00 fs/ntfs/inode.c:3051 ntfs_commit_inode fs/ntfs/inode.h:300 [inline] ntfs_put_super+0xa7/0x1070 fs/ntfs/super.c:2268 generic_shutdown_super+0x134/0x2b0 fs/super.c:693 kill_block_super+0x44/0x90 fs/super.c:1660 deactivate_locked_super+0x97/0x100 fs/super.c:481 cleanup_mnt+0x43b/0x4d0 fs/namespace.c:1259 task_work_run+0x1d4/0x260 kernel/task_work.c:245 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0xe6/0x110 kernel/entry/common.c:177 exit_to_user_mode_prepare+0xee/0x180 kernel/entry/common.c:210 __syscall_exit_to_user_mode_work kernel/entry/common.c:291 [inline] syscall_exit_to_user_mode+0x1a/0x50 kernel/entry/common.c:302 do_syscall_64+0x61/0xb0 arch/x86/entry/common.c:82 entry_SYSCALL_64_after_hwframe+0x68/0xd2 other info that might help us debug this: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&ni->mrec_lock); lock(&rl->lock); lock(&ni->mrec_lock); rlock(&rl->lock); *** DEADLOCK *** 2 locks held by syz-executor/5774: #0: ffff88805931a0e0 (&type->s_umount_key#59){++++}-{3:3}, at: __super_lock fs/super.c:56 [inline] #0: ffff88805931a0e0 (&type->s_umount_key#59){++++}-{3:3}, at: __super_lock_excl fs/super.c:71 [inline] #0: ffff88805931a0e0 (&type->s_umount_key#59){++++}-{3:3}, at: deactivate_super+0xa4/0xe0 fs/super.c:513 #1: ffff88805ed34390 (&ni->mrec_lock){+.+.}-{3:3}, at: map_mft_record+0x50/0x650 fs/ntfs/mft.c:154 stack backtrace: CPU: 1 PID: 5774 Comm: syz-executor Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/18/2026 Call Trace: dump_stack_lvl+0x18c/0x250 lib/dump_stack.c:106 check_noncircular+0x2fc/0x400 kernel/locking/lockdep.c:2187 check_prev_add kernel/locking/lockdep.c:3134 [inline] check_prevs_add kernel/locking/lockdep.c:3253 [inline] validate_chain kernel/locking/lockdep.c:3869 [inline] __lock_acquire+0x2df1/0x7d40 kernel/locking/lockdep.c:5137 lock_acquire+0x19e/0x420 kernel/locking/lockdep.c:5754 down_read+0x46/0x2e0 kernel/locking/rwsem.c:1520 ntfs_read_block fs/ntfs/aops.c:248 [inline] ntfs_read_folio+0x145d/0x2990 fs/ntfs/aops.c:436 filemap_read_folio+0x172/0x760 mm/filemap.c:2420 do_read_cache_folio+0x468/0x7d0 mm/filemap.c:3809 do_read_cache_page+0x32/0x250 mm/filemap.c:3875 read_mapping_page include/linux/pagemap.h:892 [inline] ntfs_map_page fs/ntfs/aops.h:75 [inline] ntfs_sync_mft_mirror+0x253/0x1ac0 fs/ntfs/mft.c:480 write_mft_record_nolock+0x1424/0x18f0 fs/ntfs/mft.c:805 write_mft_record+0x136/0x300 fs/ntfs/mft.h:95 __ntfs_write_inode+0x731/0xc00 fs/ntfs/inode.c:3051 ntfs_commit_inode fs/ntfs/inode.h:300 [inline] ntfs_put_super+0xa7/0x1070 fs/ntfs/super.c:2268 generic_shutdown_super+0x134/0x2b0 fs/super.c:693 kill_block_super+0x44/0x90 fs/super.c:1660 deactivate_locked_super+0x97/0x100 fs/super.c:481 cleanup_mnt+0x43b/0x4d0 fs/namespace.c:1259 task_work_run+0x1d4/0x260 kernel/task_work.c:245 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0xe6/0x110 kernel/entry/common.c:177 exit_to_user_mode_prepare+0xee/0x180 kernel/entry/common.c:210 __syscall_exit_to_user_mode_work kernel/entry/common.c:291 [inline] syscall_exit_to_user_mode+0x1a/0x50 kernel/entry/common.c:302 do_syscall_64+0x61/0xb0 arch/x86/entry/common.c:82 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7fd67559e097 Code: a2 c7 05 5c 06 25 00 00 00 00 00 eb 96 e8 e1 12 00 00 90 31 f6 e9 09 00 00 00 66 0f 1f 84 00 00 00 00 00 b8 a6 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 c7 c2 e8 ff ff ff f7 d8 64 89 02 b8 RSP: 002b:00007ffd99b3a2a8 EFLAGS: 00000246 ORIG_RAX: 00000000000000a6 RAX: 0000000000000000 RBX: 00007fd6756321ca RCX: 00007fd67559e097 RDX: 0000000000000000 RSI: 0000000000000009 RDI: 00007ffd99b3a360 RBP: 00007ffd99b3a360 R08: 00007ffd99b3b360 R09: 00000000ffffffff R10: 0000000000000000 R11: 0000000000000246 R12: 00007ffd99b3b3f0 R13: 00007fd6756321ca R14: 00000000000bacc7 R15: 00007ffd99b3b430