EXT4-fs error (device loop4): ext4_readdir:260: inode #2: block 48: comm syz-executor: path /5/file0: bad entry in directory: rec_len is smaller than minimal - offset=980, inode=0, rec_len=0, size=1024 fake=0 ================================================================== BUG: KASAN: slab-out-of-bounds in ext4_read_inline_data fs/ext4/inline.c:209 [inline] BUG: KASAN: slab-out-of-bounds in ext4_read_inline_dir+0x48b/0xdf0 fs/ext4/inline.c:1483 Read of size 836 at addr ffff888022ae7205 by task syz-executor/5221 CPU: 1 UID: 0 PID: 5221 Comm: syz-executor Not tainted 6.11.0-rc6-syzkaller-00048-gc7fb1692dc01 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/06/2024 Call Trace: __dump_stack lib/dump_stack.c:93 [inline] dump_stack_lvl+0x241/0x360 lib/dump_stack.c:119 print_address_description mm/kasan/report.c:377 [inline] print_report+0x169/0x550 mm/kasan/report.c:488 kasan_report+0x143/0x180 mm/kasan/report.c:601 kasan_check_range+0x282/0x290 mm/kasan/generic.c:189 __asan_memcpy+0x29/0x70 mm/kasan/shadow.c:105 ext4_read_inline_data fs/ext4/inline.c:209 [inline] ext4_read_inline_dir+0x48b/0xdf0 fs/ext4/inline.c:1483 ext4_readdir+0x3bb/0x3500 fs/ext4/dir.c:158 iterate_dir+0x57a/0x810 fs/readdir.c:108 __do_sys_getdents64 fs/readdir.c:407 [inline] __se_sys_getdents64+0x20d/0x4f0 fs/readdir.c:392 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f74a7faf093 Code: c1 66 0f 1f 44 00 00 48 83 c4 08 48 89 ef 5b 5d e9 42 43 f8 ff 66 90 b8 ff ff ff 7f 48 39 c2 48 0f 47 d0 b8 d9 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 05 c3 0f 1f 40 00 48 c7 c2 a8 ff ff ff f7 d8 RSP: 002b:00007ffdf4eef508 EFLAGS: 00000293 ORIG_RAX: 00000000000000d9 RAX: ffffffffffffffda RBX: 000055557cef6640 RCX: 00007f74a7faf093 RDX: 0000000000008000 RSI: 000055557cef6640 RDI: 0000000000000006 RBP: 000055557cef6614 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000001000 R11: 0000000000000293 R12: ffffffffffffffa8 R13: 0000000000000016 R14: 000055557cef6610 R15: 00007ffdf4ef28a0 Allocated by task 3033: kasan_save_stack mm/kasan/common.c:47 [inline] kasan_save_track+0x3f/0x80 mm/kasan/common.c:68 poison_kmalloc_redzone mm/kasan/common.c:370 [inline] __kasan_kmalloc+0x98/0xb0 mm/kasan/common.c:387 kasan_kmalloc include/linux/kasan.h:211 [inline] __kmalloc_cache_noprof+0x19c/0x2c0 mm/slub.c:4193 kmalloc_noprof include/linux/slab.h:681 [inline] kzalloc_noprof include/linux/slab.h:807 [inline] ref_tracker_alloc+0x14b/0x490 lib/ref_tracker.c:203 __netdev_tracker_alloc include/linux/netdevice.h:4047 [inline] netdev_hold include/linux/netdevice.h:4076 [inline] dst_init+0xee/0x490 net/core/dst.c:52 dst_alloc+0x14f/0x190 net/core/dst.c:93 ip6_dst_alloc net/ipv6/route.c:342 [inline] icmp6_dst_alloc+0x77/0x420 net/ipv6/route.c:3275 mld_sendpack+0x6a3/0xdb0 net/ipv6/mcast.c:1807 ipv6_mc_dad_complete+0x88/0x490 net/ipv6/mcast.c:2244 addrconf_dad_completed+0x712/0xcd0 net/ipv6/addrconf.c:4340 addrconf_dad_work+0xdc2/0x16f0 process_one_work kernel/workqueue.c:3231 [inline] process_scheduled_works+0xa2c/0x1830 kernel/workqueue.c:3312 worker_thread+0x86d/0xd10 kernel/workqueue.c:3389 kthread+0x2f0/0x390 kernel/kthread.c:389 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244 The buggy address belongs to the object at ffff888022ae7200 which belongs to the cache kmalloc-32 of size 32 The buggy address is located 5 bytes inside of allocated 32-byte region [ffff888022ae7200, ffff888022ae7220) The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x22ae7 ksm flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) page_type: 0xfdffffff(slab) raw: 00fff00000000000 ffff88801a841780 ffffea000090aa40 dead000000000003 raw: 0000000000000000 0000000000400040 00000001fdffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x52cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP), pid 1, tgid 1 (swapper/0), ts 3598805445, free_ts 0 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1f3/0x230 mm/page_alloc.c:1500 prep_new_page mm/page_alloc.c:1508 [inline] get_page_from_freelist+0x2e4c/0x2f10 mm/page_alloc.c:3446 __alloc_pages_noprof+0x256/0x6c0 mm/page_alloc.c:4702 __alloc_pages_node_noprof include/linux/gfp.h:269 [inline] alloc_pages_node_noprof include/linux/gfp.h:296 [inline] alloc_slab_page+0x5f/0x120 mm/slub.c:2325 allocate_slab+0x5a/0x2f0 mm/slub.c:2488 new_slab mm/slub.c:2541 [inline] ___slab_alloc+0xcd1/0x14b0 mm/slub.c:3727 __slab_alloc+0x58/0xa0 mm/slub.c:3817 __slab_alloc_node mm/slub.c:3870 [inline] slab_alloc_node mm/slub.c:4029 [inline] __do_kmalloc_node mm/slub.c:4161 [inline] __kmalloc_noprof+0x25a/0x400 mm/slub.c:4174 acpi_ut_initialize_buffer+0x1d1/0x2c0 acpi_evaluate_object+0x8ab/0xaf0 drivers/acpi/acpica/nsxfeval.c:400 map_mat_entry drivers/acpi/processor_core.c:241 [inline] acpi_get_phys_id+0xa5/0xd00 drivers/acpi/processor_core.c:274 acpi_processor_get_info drivers/acpi/acpi_processor.c:337 [inline] acpi_processor_add+0x8b8/0x19c0 drivers/acpi/acpi_processor.c:443 acpi_scan_attach_handler drivers/acpi/scan.c:2240 [inline] acpi_bus_attach+0x7ab/0xcb0 drivers/acpi/scan.c:2289 device_for_each_child+0xf5/0x170 drivers/base/core.c:4011 acpi_dev_for_each_child+0xd0/0x110 drivers/acpi/bus.c:1157 acpi_bus_attach+0x9f4/0xcb0 drivers/acpi/scan.c:2309 page_owner free stack trace missing Memory state around the buggy address: ffff888022ae7100: 00 00 00 fc fc fc fc fc 00 00 00 fc fc fc fc fc ffff888022ae7180: 00 00 03 fc fc fc fc fc 00 00 00 01 fc fc fc fc >ffff888022ae7200: 00 00 00 00 fc fc fc fc 00 00 00 02 fc fc fc fc ^ ffff888022ae7280: 00 00 05 fc fc fc fc fc 00 00 00 fc fc fc fc fc ffff888022ae7300: 00 00 00 00 fc fc fc fc 00 00 00 00 fc fc fc fc ==================================================================