ntfs: (device loop2): ntfs_read_locked_inode(): Failed with error code -5. Marking corrupt inode 0xa as bad. Run chkdsk. ntfs: (device loop2): load_and_init_upcase(): Failed to load $UpCase from the volume. Using default. ntfs: volume version 3.1. ntfs: (device loop2): map_mft_record_page(): Mft record 0x2 is corrupt. Run chkdsk. ================================================================== BUG: KASAN: use-after-free in ntfs_ucsncmp fs/ntfs/unistr.c:142 [inline] BUG: KASAN: use-after-free in ntfs_are_names_equal+0x2f8/0x340 fs/ntfs/unistr.c:61 Read of size 2 at addr ffff888037e71ee8 by task syz-executor.2/8361 CPU: 1 PID: 8361 Comm: syz-executor.2 Not tainted 5.10.0-rc2-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x1d6/0x29e lib/dump_stack.c:118 print_address_description+0x6c/0x640 mm/kasan/report.c:385 __kasan_report mm/kasan/report.c:545 [inline] kasan_report+0x136/0x1e0 mm/kasan/report.c:562 ntfs_ucsncmp fs/ntfs/unistr.c:142 [inline] ntfs_are_names_equal+0x2f8/0x340 fs/ntfs/unistr.c:61 ntfs_attr_find+0x36d/0xac0 fs/ntfs/attrib.c:614 ntfs_attr_lookup+0x1ec/0x23f0 fs/ntfs/attrib.c:1189 ntfs_read_locked_attr_inode fs/ntfs/inode.c:1233 [inline] ntfs_attr_iget+0x48c/0x2190 fs/ntfs/inode.c:238 ntfs_read_locked_inode+0x36d0/0x4e00 fs/ntfs/inode.c:954 ntfs_iget+0xc2/0x130 fs/ntfs/inode.c:177 load_system_files fs/ntfs/super.c:1974 [inline] ntfs_fill_super+0x5e1c/0x8df0 fs/ntfs/super.c:2893 mount_bdev+0x24f/0x360 fs/super.c:1419 legacy_get_tree+0xea/0x180 fs/fs_context.c:592 vfs_get_tree+0x88/0x270 fs/super.c:1549 do_new_mount fs/namespace.c:2875 [inline] path_mount+0x17b4/0x2a20 fs/namespace.c:3205 do_mount fs/namespace.c:3218 [inline] __do_sys_mount fs/namespace.c:3426 [inline] __se_sys_mount+0x28c/0x320 fs/namespace.c:3403 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 RIP: 0033:0x4608aa Code: b8 a6 00 00 00 0f 05 48 3d 01 f0 ff ff 0f 83 ad 89 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 0f 83 8a 89 fb ff c3 66 0f 1f 84 00 00 00 00 00 RSP: 002b:00007f8f72ac8a88 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 00007f8f72ac8b20 RCX: 00000000004608aa RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007f8f72ac8ae0 RBP: 00007f8f72ac8ae0 R08: 00007f8f72ac8b20 R09: 0000000020000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000020000000 R13: 0000000020000100 R14: 0000000020000200 R15: 000000002007dc00 The buggy address belongs to the page: page:00000000f0edeef2 refcount:0 mapcount:0 mapping:0000000000000000 index:0x1 pfn:0x37e71 flags: 0xfffe0000000000() raw: 00fffe0000000000 ffffea0000de81c8 ffffea0000df9bc8 0000000000000000 raw: 0000000000000001 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888037e71d80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888037e71e00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff888037e71e80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff888037e71f00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888037e71f80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================