hpfs: hpfs_map_sector(): read error hpfs: code page support is disabled ================================================================== BUG: KASAN: use-after-free in strcmp+0x6b/0xb0 lib/string.c:361 Read of size 1 at addr ffff8880543558a6 by task syz.3.21/4504 CPU: 0 PID: 4504 Comm: syz.3.21 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025 Call Trace: dump_stack_lvl+0x168/0x22e lib/dump_stack.c:106 print_address_description mm/kasan/report.c:316 [inline] print_report+0xa8/0x210 mm/kasan/report.c:420 kasan_report+0x10b/0x140 mm/kasan/report.c:524 strcmp+0x6b/0xb0 lib/string.c:361 hpfs_get_ea+0x111/0xc80 fs/hpfs/ea.c:139 hpfs_read_inode+0x19a/0x1000 fs/hpfs/inode.c:63 hpfs_fill_super+0x12d1/0x1eb0 fs/hpfs/super.c:712 mount_bdev+0x287/0x3c0 fs/super.c:1443 legacy_get_tree+0xe6/0x180 fs/fs_context.c:632 vfs_get_tree+0x88/0x270 fs/super.c:1573 do_new_mount+0x24a/0xa40 fs/namespace.c:3069 do_mount fs/namespace.c:3412 [inline] __do_sys_mount fs/namespace.c:3620 [inline] __se_sys_mount+0x2d6/0x3c0 fs/namespace.c:3597 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7fd50379076a Code: d8 64 89 02 48 c7 c0 ff ff ff ff eb a6 e8 de 1a 00 00 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fd5045eae68 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 00007fd5045eaef0 RCX: 00007fd50379076a RDX: 000020000000a000 RSI: 0000200000000000 RDI: 00007fd5045eaeb0 RBP: 000020000000a000 R08: 00007fd5045eaef0 R09: 0000000003200041 R10: 0000000003200041 R11: 0000000000000246 R12: 0000200000000000 R13: 00007fd5045eaeb0 R14: 0000000000009e15 R15: 0000200000000040 The buggy address belongs to the physical page: page:ffffea000150d540 refcount:1 mapcount:0 mapping:ffff88805581fb58 index:0x67e pfn:0x54355 memcg:ffff888072f1c000 aops:shmem_aops ino:23 dentry name(?):"core" flags: 0xfff6000008001e(referenced|uptodate|dirty|lru|swapbacked|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff6000008001e ffffea000150d508 ffffea000150d588 ffff88805581fb58 raw: 000000000000067e 0000000000000000 00000001ffffffff ffff888072f1c000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Movable, gfp_mask 0x140cca(GFP_HIGHUSER_MOVABLE|__GFP_COMP), pid 4528, tgid 4528 (syz.1.23), ts 87111585980, free_ts 85735508917 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x173/0x1a0 mm/page_alloc.c:2532 prep_new_page mm/page_alloc.c:2539 [inline] get_page_from_freelist+0x1a26/0x1ac0 mm/page_alloc.c:4328 __alloc_pages+0x1df/0x4e0 mm/page_alloc.c:5614 __folio_alloc+0xe/0x30 mm/page_alloc.c:5646 vma_alloc_folio+0x4a3/0x900 mm/mempolicy.c:2243 shmem_alloc_folio mm/shmem.c:1589 [inline] shmem_alloc_and_acct_folio+0x42e/0xb60 mm/shmem.c:1613 shmem_get_folio_gfp+0x1361/0x3400 mm/shmem.c:1941 shmem_get_folio mm/shmem.c:2072 [inline] shmem_write_begin+0xee/0x3f0 mm/shmem.c:2556 generic_perform_write+0x2db/0x560 mm/filemap.c:3846 __generic_file_write_iter+0x172/0x430 mm/filemap.c:3974 generic_file_write_iter+0xab/0x2e0 mm/filemap.c:4006 __kernel_write_iter+0x26d/0x630 fs/read_write.c:517 dump_emit_page fs/coredump.c:950 [inline] dump_user_range+0x3ea/0x7f0 fs/coredump.c:977 elf_core_dump+0x2f77/0x3490 fs/binfmt_elf.c:2354 do_coredump+0x15ff/0x22b0 fs/coredump.c:824 get_signal+0x10aa/0x1350 kernel/signal.c:2857 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1459 [inline] free_pcp_prepare mm/page_alloc.c:1509 [inline] free_unref_page_prepare+0x8b4/0x9a0 mm/page_alloc.c:3384 free_unref_page_list+0xbb/0x8e0 mm/page_alloc.c:3525 release_pages+0x1f92/0x2200 mm/swap.c:1035 __pagevec_release+0x6d/0xe0 mm/swap.c:1055 pagevec_release include/linux/pagevec.h:71 [inline] folio_batch_release include/linux/pagevec.h:135 [inline] shmem_undo_range+0x75b/0x2050 mm/shmem.c:946 shmem_truncate_range mm/shmem.c:1062 [inline] shmem_evict_inode+0x248/0xa40 mm/shmem.c:1171 evict+0x485/0x870 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+0x1ca/0x250 kernel/task_work.c:203 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:292 [inline] syscall_exit_to_user_mode+0x16/0x40 kernel/entry/common.c:303 do_syscall_64+0x58/0xa0 arch/x86/entry/common.c:87 Memory state around the buggy address: ffff888054355780: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888054355800: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff888054355880: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffff888054355900: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888054355980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================