================================================================== BUG: KASAN: use-after-free in ext4_xattr_delete_inode+0xba6/0xbb0 fs/ext4/xattr.c:2913 Read of size 4 at addr ffff88812c6bc000 by task syz-executor/441 CPU: 0 PID: 441 Comm: syz-executor Not tainted 6.1.138-syzkaller-1169883-gba4506940166 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025 Call Trace: __dump_stack+0x21/0x24 lib/dump_stack.c:88 dump_stack_lvl+0xee/0x150 lib/dump_stack.c:106 print_address_description+0x71/0x210 mm/kasan/report.c:316 print_report+0x4a/0x60 mm/kasan/report.c:427 kasan_report+0x122/0x150 mm/kasan/report.c:531 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report_generic.c:350 ext4_xattr_delete_inode+0xba6/0xbb0 fs/ext4/xattr.c:2913 ext4_evict_inode+0xe58/0x1460 fs/ext4/inode.c:296 evict+0x493/0x890 fs/inode.c:705 iput_final fs/inode.c:1834 [inline] iput+0x620/0x670 fs/inode.c:1860 d_delete_notify include/linux/fsnotify.h:292 [inline] vfs_rmdir+0x3bf/0x500 fs/namei.c:4203 do_rmdir+0x259/0x6a0 fs/namei.c:4251 __do_sys_unlinkat fs/namei.c:4431 [inline] __se_sys_unlinkat fs/namei.c:4425 [inline] __x64_sys_unlinkat+0xc7/0xf0 fs/namei.c:4425 x64_sys_call+0x79f/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:264 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:0x7fc9cc57d5d7 Code: 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 b8 07 01 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:00007ffe6a171b48 EFLAGS: 00000207 ORIG_RAX: 0000000000000107 RAX: ffffffffffffffda RBX: 0000000000000065 RCX: 00007fc9cc57d5d7 RDX: 0000000000000200 RSI: 00007ffe6a172cf0 RDI: 00000000ffffff9c RBP: 00007fc9cc5f0134 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000100 R11: 0000000000000207 R12: 00007ffe6a172cf0 R13: 00007fc9cc5f0134 R14: 000000000000d290 R15: 00007ffe6a174ea0 Allocated by task 346: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4b/0x70 mm/kasan/common.c:52 kasan_save_alloc_info+0x25/0x30 mm/kasan/generic.c:505 __kasan_slab_alloc+0x72/0x80 mm/kasan/common.c:333 kasan_slab_alloc include/linux/kasan.h:202 [inline] slab_post_alloc_hook+0x4f/0x2d0 mm/slab.h:768 slab_alloc_node mm/slub.c:3421 [inline] slab_alloc mm/slub.c:3431 [inline] __kmem_cache_alloc_lru mm/slub.c:3438 [inline] kmem_cache_alloc+0x16e/0x330 mm/slub.c:3447 vm_area_alloc+0x24/0x1a0 kernel/fork.c:495 do_brk_flags+0x536/0x1220 mm/mmap.c:3231 __do_sys_brk mm/mmap.c:271 [inline] __se_sys_brk+0x924/0xa90 mm/mmap.c:176 __x64_sys_brk+0x38/0x40 mm/mmap.c:176 x64_sys_call+0x920/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:13 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 Freed by task 346: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4b/0x70 mm/kasan/common.c:52 kasan_save_free_info+0x31/0x50 mm/kasan/generic.c:516 ____kasan_slab_free+0x132/0x180 mm/kasan/common.c:241 __kasan_slab_free+0x11/0x20 mm/kasan/common.c:249 kasan_slab_free include/linux/kasan.h:178 [inline] slab_free_hook mm/slub.c:1745 [inline] slab_free_freelist_hook+0xc2/0x190 mm/slub.c:1771 slab_free mm/slub.c:3686 [inline] kmem_cache_free+0x12d/0x300 mm/slub.c:3711 __vm_area_free+0x7e/0x130 kernel/fork.c:536 remove_vma mm/mmap.c:148 [inline] exit_mmap+0x490/0xa40 mm/mmap.c:3369 __mmput+0x93/0x320 kernel/fork.c:1297 mmput+0x4b/0x150 kernel/fork.c:1320 exit_mm kernel/exit.c:568 [inline] do_exit+0x979/0x2650 kernel/exit.c:864 do_group_exit+0x210/0x2d0 kernel/exit.c:1027 get_signal+0x13b5/0x1520 kernel/signal.c:2889 arch_do_signal_or_restart+0xb0/0x1030 arch/x86/kernel/signal.c:871 exit_to_user_mode_loop+0x7a/0xb0 kernel/entry/common.c:174 exit_to_user_mode_prepare+0x5a/0xa0 kernel/entry/common.c:210 __syscall_exit_to_user_mode_work kernel/entry/common.c:292 [inline] syscall_exit_to_user_mode+0x1a/0x30 kernel/entry/common.c:303 do_syscall_64+0x58/0xa0 arch/x86/entry/common.c:87 entry_SYSCALL_64_after_hwframe+0x68/0xd2 The buggy address belongs to the object at ffff88812c6bc000 which belongs to the cache vm_area_struct of size 200 The buggy address is located 0 bytes inside of 200-byte region [ffff88812c6bc000, ffff88812c6bc0c8) The buggy address belongs to the physical page: page:ffffea0004b1af00 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x12c6bc flags: 0x4000000000000200(slab|zone=1) raw: 4000000000000200 0000000000000000 dead000000000122 ffff8881002aa900 raw: 0000000000000000 00000000000f000f 00000001ffffffff 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 0x112cc0(GFP_USER|__GFP_NOWARN|__GFP_NORETRY), pid 346, tgid 346 (syz-executor), ts 31250753850, free_ts 31250564335 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0x1f5/0x210 mm/page_alloc.c:2637 prep_new_page+0x1c/0x110 mm/page_alloc.c:2644 get_page_from_freelist+0x2c7b/0x2cf0 mm/page_alloc.c:4539 __alloc_pages+0x19e/0x3a0 mm/page_alloc.c:5842 alloc_slab_page+0x6e/0xf0 include/linux/gfp.h:-1 allocate_slab mm/slub.c:1962 [inline] new_slab+0x98/0x3d0 mm/slub.c:2015 ___slab_alloc+0x6f6/0xb50 mm/slub.c:3203 __slab_alloc+0x5e/0xa0 mm/slub.c:3302 slab_alloc_node mm/slub.c:3387 [inline] slab_alloc mm/slub.c:3431 [inline] __kmem_cache_alloc_lru mm/slub.c:3438 [inline] kmem_cache_alloc+0x1b0/0x330 mm/slub.c:3447 vm_area_alloc+0x24/0x1a0 kernel/fork.c:495 __mmap_region mm/mmap.c:2837 [inline] mmap_region+0xf7d/0x2140 mm/mmap.c:3005 do_mmap+0x7ae/0xcf0 mm/mmap.c:1474 vm_mmap_pgoff+0x1f5/0x3f0 mm/util.c:525 vm_mmap+0x87/0xb0 mm/util.c:545 elf_map+0x1aa/0x300 fs/binfmt_elf.c:394 load_elf_binary+0xfb4/0x2710 fs/binfmt_elf.c:1167 page last free stack trace: reset_page_owner include/linux/page_owner.h:26 [inline] free_pages_prepare mm/page_alloc.c:1545 [inline] free_pcp_prepare mm/page_alloc.c:1619 [inline] free_unref_page_prepare+0x742/0x750 mm/page_alloc.c:3581 free_unref_page_list+0xba/0x7c0 mm/page_alloc.c:3729 release_pages+0xad1/0xb20 mm/swap.c:1043 free_pages_and_swap_cache+0x86/0xa0 mm/swap_state.c:315 tlb_batch_pages_flush mm/mmu_gather.c:59 [inline] tlb_flush_mmu_free mm/mmu_gather.c:254 [inline] tlb_flush_mmu mm/mmu_gather.c:261 [inline] tlb_finish_mmu+0x1aa/0x370 mm/mmu_gather.c:361 shift_arg_pages fs/exec.c:736 [inline] setup_arg_pages+0xa47/0xc30 fs/exec.c:836 load_elf_binary+0xb98/0x2710 fs/binfmt_elf.c:1020 search_binary_handler fs/exec.c:1743 [inline] exec_binprm fs/exec.c:1784 [inline] bprm_execve+0x787/0x1440 fs/exec.c:1853 do_execveat_common+0x915/0xa70 fs/exec.c:1958 do_execve fs/exec.c:2032 [inline] __do_sys_execve fs/exec.c:2108 [inline] __se_sys_execve fs/exec.c:2103 [inline] __x64_sys_execve+0x92/0xb0 fs/exec.c:2103 x64_sys_call+0x98/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:60 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 Memory state around the buggy address: ffff88812c6bbf00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88812c6bbf80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88812c6bc000: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff88812c6bc080: fb fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc ffff88812c6bc100: fc fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb ================================================================== EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem. EXT4-fs (loop0): unmounting filesystem.