BUG: KASAN: slab-out-of-bounds in hfsplus_uni2asc+0x910/0xa20 fs/hfsplus/unicode.c:179 Read of size 2 at addr ffff88801a65640c by task syz-executor266/5169 CPU: 2 PID: 5169 Comm: syz-executor266 Not tainted 6.8.0-rc7-syzkaller-00130-g135288b73cef #0 Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.2-debian-1.16.2-1 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd9/0x1b0 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:377 [inline] print_report+0xc4/0x620 mm/kasan/report.c:488 kasan_report+0xda/0x110 mm/kasan/report.c:601 hfsplus_uni2asc+0x910/0xa20 fs/hfsplus/unicode.c:179 hfsplus_readdir+0x87b/0x1000 fs/hfsplus/dir.c:207 iterate_dir+0x292/0x9e0 fs/readdir.c:110 __do_sys_getdents64 fs/readdir.c:409 [inline] __se_sys_getdents64 fs/readdir.c:394 [inline] __x64_sys_getdents64+0x14f/0x2e0 fs/readdir.c:394 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xd5/0x270 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x6f/0x77 RIP: 0033:0x7f4e8c8226f9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 61 17 00 00 90 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 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fffa1baa138 EFLAGS: 00000246 ORIG_RAX: 00000000000000d9 RAX: ffffffffffffffda RBX: 000000000000003f RCX: 00007f4e8c8226f9 RDX: 0000000000000061 RSI: 0000000020000340 RDI: 0000000000000004 RBP: 00007f4e8c895610 R08: 00007fffa1baa308 R09: 00007fffa1baa308 R10: 00007fffa1baa308 R11: 0000000000000246 R12: 0000000000000001 R13: 00007fffa1baa2f8 R14: 0000000000000001 R15: 0000000000000001 Allocated by task 5169: kasan_save_stack+0x33/0x60 mm/kasan/common.c:47 kasan_save_track+0x14/0x30 mm/kasan/common.c:68 poison_kmalloc_redzone mm/kasan/common.c:370 [inline] __kasan_kmalloc+0xaa/0xb0 mm/kasan/common.c:387 kasan_kmalloc include/linux/kasan.h:211 [inline] __do_kmalloc_node mm/slub.c:3981 [inline] __kmalloc+0x1f9/0x440 mm/slub.c:3994 kmalloc include/linux/slab.h:594 [inline] hfsplus_find_init+0x95/0x200 fs/hfsplus/bfind.c:21 hfsplus_readdir+0x266/0x1000 fs/hfsplus/dir.c:144 iterate_dir+0x292/0x9e0 fs/readdir.c:110 __do_sys_getdents64 fs/readdir.c:409 [inline] __se_sys_getdents64 fs/readdir.c:394 [inline] __x64_sys_getdents64+0x14f/0x2e0 fs/readdir.c:394 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xd5/0x270 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x6f/0x77 The buggy address belongs to the object at ffff88801a656000 which belongs to the cache kmalloc-2k of size 2048 The buggy address is located 0 bytes to the right of allocated 1036-byte region [ffff88801a656000, ffff88801a65640c) The buggy address belongs to the physical page: page:ffffea0000699400 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1a650 head:ffffea0000699400 order:3 entire_mapcount:0 nr_pages_mapped:0 pincount:0 flags: 0xfff00000000840(slab|head|node=0|zone=1|lastcpupid=0x7ff) page_type: 0xffffffff() raw: 00fff00000000840 ffff888014c42f00 dead000000000100 dead000000000122 raw: 0000000000000000 0000000080080008 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 3, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 1, tgid 1 (swapper/0), ts 3634752467, free_ts 0 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x2d4/0x350 mm/page_alloc.c:1533 prep_new_page mm/page_alloc.c:1540 [inline] get_page_from_freelist+0xa28/0x3780 mm/page_alloc.c:3311 __alloc_pages+0x22f/0x2440 mm/page_alloc.c:4567 __alloc_pages_node include/linux/gfp.h:238 [inline] alloc_pages_node include/linux/gfp.h:261 [inline] alloc_slab_page mm/slub.c:2190 [inline] allocate_slab mm/slub.c:2354 [inline] new_slab+0xcc/0x3a0 mm/slub.c:2407 ___slab_alloc+0x4af/0x19a0 mm/slub.c:3540 __slab_alloc.constprop.0+0x56/0xb0 mm/slub.c:3625 __slab_alloc_node mm/slub.c:3678 [inline] slab_alloc_node mm/slub.c:3850 [inline] kmalloc_trace+0x30b/0x340 mm/slub.c:4007 kmalloc include/linux/slab.h:590 [inline] kzalloc include/linux/slab.h:711 [inline] acpi_os_allocate_zeroed include/acpi/platform/aclinuxex.h:57 [inline] acpi_ds_create_walk_state+0x78/0x250 drivers/acpi/acpica/dswstate.c:518 acpi_ds_call_control_method+0xeb/0x6c0 drivers/acpi/acpica/dsmethod.c:498 acpi_ps_parse_aml+0x845/0xcb0 drivers/acpi/acpica/psparse.c:503 acpi_ps_execute_method+0x55a/0xb30 drivers/acpi/acpica/psxface.c:190 acpi_ns_evaluate+0x76c/0xca0 drivers/acpi/acpica/nseval.c:205 acpi_evaluate_object+0x3eb/0xa70 drivers/acpi/acpica/nsxfeval.c:354 acpi_evaluate_integer+0xde/0x200 drivers/acpi/utils.c:260 acpi_bus_get_status_handle drivers/acpi/bus.c:82 [inline] acpi_bus_get_status+0x19e/0x340 drivers/acpi/bus.c:111 acpi_scan_init_status drivers/acpi/scan.c:1822 [inline] acpi_add_single_object+0x12d/0x1b10 drivers/acpi/scan.c:1855 page_owner free stack trace missing Memory state around the buggy address: ffff88801a656300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88801a656380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88801a656400: 00 04 fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88801a656480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88801a656500: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================