loop2: detected capacity change from 0 to 4096 ====================================================== WARNING: possible circular locking dependency detected syzkaller #0 Not tainted ------------------------------------------------------ syz.2.528/10819 is trying to acquire lock: ffff88804057dd30 (&ni->ni_lock#2/5){+.+.}-{4:4}, at: ni_lock fs/ntfs3/ntfs_fs.h:1127 [inline] ffff88804057dd30 (&ni->ni_lock#2/5){+.+.}-{4:4}, at: ntfs_fallocate+0x7f3/0x1140 fs/ntfs3/file.c:690 but task is already holding lock: ffff88804057e1b8 (mapping.invalidate_lock#9){++++}-{4:4}, at: filemap_invalidate_lock include/linux/fs.h:1083 [inline] ffff88804057e1b8 (mapping.invalidate_lock#9){++++}-{4:4}, at: ntfs_fallocate+0x3c3/0x1140 fs/ntfs3/file.c:620 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #2 (mapping.invalidate_lock#9){++++}-{4:4}: down_read+0x97/0x200 kernel/locking/rwsem.c:1537 filemap_invalidate_lock_shared include/linux/fs.h:1093 [inline] filemap_fault+0x66f/0x12f0 mm/filemap.c:3537 __do_fault+0x138/0x390 mm/memory.c:5323 do_read_fault mm/memory.c:5758 [inline] do_fault mm/memory.c:5892 [inline] do_pte_missing+0x18d3/0x2e60 mm/memory.c:4404 handle_pte_fault mm/memory.c:6276 [inline] __handle_mm_fault mm/memory.c:6414 [inline] handle_mm_fault+0xd0a/0x13c0 mm/memory.c:6583 do_user_addr_fault+0x75b/0x1360 arch/x86/mm/fault.c:1385 handle_page_fault arch/x86/mm/fault.c:1474 [inline] exc_page_fault+0x6a/0xc0 arch/x86/mm/fault.c:1527 asm_exc_page_fault+0x26/0x30 arch/x86/include/asm/idtentry.h:618 fault_in_readable+0x8e/0x130 mm/gup.c:-1 fault_in_iov_iter_readable+0x1b4/0x2f0 lib/iov_iter.c:106 generic_perform_write+0x765/0x8b0 mm/filemap.c:4363 ntfs_file_write_iter+0x74b/0x870 fs/ntfs3/file.c:1319 new_sync_write fs/read_write.c:595 [inline] vfs_write+0x629/0xba0 fs/read_write.c:688 ksys_pwrite64 fs/read_write.c:795 [inline] __do_sys_pwrite64 fs/read_write.c:803 [inline] __se_sys_pwrite64 fs/read_write.c:800 [inline] __x64_sys_pwrite64+0x19c/0x230 fs/read_write.c:800 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x14d/0xf80 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f -> #1 (&mm->mmap_lock){++++}-{4:4}: __might_fault+0xcb/0x130 mm/memory.c:7177 _inline_copy_to_user include/linux/uaccess.h:201 [inline] _copy_to_user+0x2c/0xb0 lib/usercopy.c:26 copy_to_user include/linux/uaccess.h:236 [inline] fiemap_fill_next_extent+0x1dd/0x3c0 fs/ioctl.c:144 ni_fiemap+0x9a5/0xca0 fs/ntfs3/frecord.c:2009 ntfs_fiemap+0x11d/0x1a0 fs/ntfs3/file.c:1420 ioctl_fiemap fs/ioctl.c:219 [inline] do_vfs_ioctl+0x126f/0x1540 fs/ioctl.c:531 __do_sys_ioctl fs/ioctl.c:595 [inline] __se_sys_ioctl+0x82/0x170 fs/ioctl.c:583 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x14d/0xf80 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f -> #0 (&ni->ni_lock#2/5){+.+.}-{4:4}: check_prev_add kernel/locking/lockdep.c:3165 [inline] check_prevs_add kernel/locking/lockdep.c:3284 [inline] validate_chain kernel/locking/lockdep.c:3908 [inline] __lock_acquire+0x15a5/0x2cf0 kernel/locking/lockdep.c:5237 lock_acquire+0x106/0x330 kernel/locking/lockdep.c:5868 __mutex_lock_common kernel/locking/rtmutex_api.c:533 [inline] mutex_lock_nested+0x5a/0x1d0 kernel/locking/rtmutex_api.c:552 ni_lock fs/ntfs3/ntfs_fs.h:1127 [inline] ntfs_fallocate+0x7f3/0x1140 fs/ntfs3/file.c:690 vfs_fallocate+0x672/0x7f0 fs/open.c:340 ksys_fallocate fs/open.c:364 [inline] __do_sys_fallocate fs/open.c:369 [inline] __se_sys_fallocate fs/open.c:367 [inline] __x64_sys_fallocate+0xc0/0x110 fs/open.c:367 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x14d/0xf80 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f other info that might help us debug this: Chain exists of: &ni->ni_lock#2/5 --> &mm->mmap_lock --> mapping.invalidate_lock#9 Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(mapping.invalidate_lock#9); lock(&mm->mmap_lock); lock(mapping.invalidate_lock#9); lock(&ni->ni_lock#2/5); *** DEADLOCK *** 3 locks held by syz.2.528/10819: #0: ffff888036ffe480 (sb_writers#27){++++}-{0:0}, at: file_start_write include/linux/fs.h:2710 [inline] #0: ffff888036ffe480 (sb_writers#27){++++}-{0:0}, at: vfs_fallocate+0x5f9/0x7f0 fs/open.c:339 #1: ffff88804057dfe8 (&sb->s_type->i_mutex_key#36){+.+.}-{4:4}, at: inode_lock include/linux/fs.h:1028 [inline] #1: ffff88804057dfe8 (&sb->s_type->i_mutex_key#36){+.+.}-{4:4}, at: ntfs_fallocate+0x2f1/0x1140 fs/ntfs3/file.c:606 #2: ffff88804057e1b8 (mapping.invalidate_lock#9){++++}-{4:4}, at: filemap_invalidate_lock include/linux/fs.h:1083 [inline] #2: ffff88804057e1b8 (mapping.invalidate_lock#9){++++}-{4:4}, at: ntfs_fallocate+0x3c3/0x1140 fs/ntfs3/file.c:620 stack backtrace: CPU: 0 UID: 0 PID: 10819 Comm: syz.2.528 Not tainted syzkaller #0 PREEMPT_{RT,(full)} Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2026 Call Trace: dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120 print_circular_bug+0x2e1/0x300 kernel/locking/lockdep.c:2043 check_noncircular+0x12e/0x150 kernel/locking/lockdep.c:2175 check_prev_add kernel/locking/lockdep.c:3165 [inline] check_prevs_add kernel/locking/lockdep.c:3284 [inline] validate_chain kernel/locking/lockdep.c:3908 [inline] __lock_acquire+0x15a5/0x2cf0 kernel/locking/lockdep.c:5237 lock_acquire+0x106/0x330 kernel/locking/lockdep.c:5868 __mutex_lock_common kernel/locking/rtmutex_api.c:533 [inline] mutex_lock_nested+0x5a/0x1d0 kernel/locking/rtmutex_api.c:552 ni_lock fs/ntfs3/ntfs_fs.h:1127 [inline] ntfs_fallocate+0x7f3/0x1140 fs/ntfs3/file.c:690 vfs_fallocate+0x672/0x7f0 fs/open.c:340 ksys_fallocate fs/open.c:364 [inline] __do_sys_fallocate fs/open.c:369 [inline] __se_sys_fallocate fs/open.c:367 [inline] __x64_sys_fallocate+0xc0/0x110 fs/open.c:367 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x14d/0xf80 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f767b6bbf79 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:00007f7679916028 EFLAGS: 00000246 ORIG_RAX: 000000000000011d RAX: ffffffffffffffda RBX: 00007f767b935fa0 RCX: 00007f767b6bbf79 RDX: 0000000000004000 RSI: 0000000000000008 RDI: 0000000000000004 RBP: 00007f767b7527e0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000004000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f767b936038 R14: 00007f767b935fa0 R15: 00007ffc8cd3aac8