================================================================== BUG: KASAN: out-of-bounds in ext4_xattr_set_entry+0x10a9/0x3a70 fs/ext4/xattr.c:1754 Read of size 18446744073709551596 at addr ffff888128ac92bc by task syz-executor.0/5835 CPU: 0 PID: 5835 Comm: syz-executor.0 Not tainted 5.15.149-syzkaller-1069109-g5d96939590c0 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x151/0x1b7 lib/dump_stack.c:106 print_address_description+0x87/0x3b0 mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:427 [inline] kasan_report+0x179/0x1c0 mm/kasan/report.c:444 kasan_check_range+0x293/0x2a0 mm/kasan/generic.c:189 memmove+0x2d/0x70 mm/kasan/shadow.c:54 ext4_xattr_set_entry+0x10a9/0x3a70 fs/ext4/xattr.c:1754 ext4_xattr_ibody_set+0x124/0x390 fs/ext4/xattr.c:2237 ext4_create_inline_data+0x34c/0x640 fs/ext4/inline.c:304 ext4_prepare_inline_data+0x167/0x1f0 fs/ext4/inline.c:413 ext4_try_to_write_inline_data+0x328/0x11d0 fs/ext4/inline.c:704 ext4_write_begin+0x246/0x13d0 fs/ext4/inode.c:1168 ext4_da_write_begin+0x4a2/0xc30 fs/ext4/inode.c:2976 generic_perform_write+0x2bc/0x5a0 mm/filemap.c:3847 ext4_buffered_write_iter+0x48a/0x610 fs/ext4/file.c:270 ext4_file_write_iter+0x443/0x1c80 __kernel_write+0x5ab/0xa60 fs/read_write.c:539 __dump_emit+0x261/0x3a0 fs/coredump.c:875 dump_emit+0x381/0x3f0 fs/coredump.c:912 elf_core_dump+0x2ac4/0x3e80 fs/binfmt_elf.c:2237 do_coredump+0x1834/0x3050 fs/coredump.c:826 get_signal+0x4c8/0x1630 kernel/signal.c:2882 arch_do_signal_or_restart+0xbd/0x1680 arch/x86/kernel/signal.c:867 handle_signal_work kernel/entry/common.c:148 [inline] exit_to_user_mode_loop+0xa0/0xe0 kernel/entry/common.c:172 exit_to_user_mode_prepare+0x5a/0xa0 kernel/entry/common.c:208 irqentry_exit_to_user_mode+0x9/0x20 kernel/entry/common.c:314 irqentry_exit+0x12/0x40 kernel/entry/common.c:405 exc_page_fault+0x47a/0x830 arch/x86/mm/fault.c:1608 asm_exc_page_fault+0x27/0x30 arch/x86/include/asm/idtentry.h:568 RIP: 0033:0x0 Code: Unable to access opcode bytes at RIP 0xffffffffffffffd6. RSP: 002b:0000000020000473 EFLAGS: 00010217 RAX: 0000000000000000 RBX: 0000000000000058 RCX: 00007f2e89c26959 RDX: 00007f2e897a8fb0 RSI: 0000000000000058 RDI: 00007f2e897a8fb0 RBP: 00007f2e89c82c88 R08: 0000000000000000 R09: 0000000000000058 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 000000000000000b R14: 00007f2e89d45f80 R15: 00007ffc5ed424b8 The buggy address belongs to the page: page:ffffea0004a2b240 refcount:2 mapcount:0 mapping:ffff88810919a4d8 index:0x3 pfn:0x128ac9 memcg:ffff888121cb8000 aops:def_blk_aops ino:700000 flags: 0x4000000000022036(referenced|uptodate|lru|active|private|mappedtodisk|zone=1) raw: 4000000000022036 ffffea00049a1cc8 ffffea0004748488 ffff88810919a4d8 raw: 0000000000000003 ffff888127445f18 00000002ffffffff ffff888121cb8000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x108c40(GFP_NOFS|__GFP_NOFAIL|__GFP_HARDWALL), pid 5832, ts 197643890826, free_ts 197506663344 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0x1a3/0x1b0 mm/page_alloc.c:2604 prep_new_page+0x1b/0x110 mm/page_alloc.c:2610 get_page_from_freelist+0x3550/0x35d0 mm/page_alloc.c:4484 __alloc_pages+0x27e/0x8f0 mm/page_alloc.c:5776 __alloc_pages_node include/linux/gfp.h:591 [inline] alloc_pages_node include/linux/gfp.h:605 [inline] alloc_pages include/linux/gfp.h:618 [inline] __page_cache_alloc include/linux/pagemap.h:305 [inline] pagecache_get_page+0xb18/0xeb0 mm/filemap.c:1944 find_or_create_page include/linux/pagemap.h:418 [inline] grow_dev_page fs/buffer.c:949 [inline] grow_buffers fs/buffer.c:1014 [inline] __getblk_slow fs/buffer.c:1041 [inline] __getblk_gfp+0x21e/0x7c0 fs/buffer.c:1336 sb_getblk_gfp include/linux/buffer_head.h:368 [inline] ext4_sb_breadahead_unmovable+0x6a/0xe0 fs/ext4/super.c:238 __ext4_get_inode_loc+0xaaf/0xcd0 fs/ext4/inode.c:4423 __ext4_get_inode_loc_noinmem fs/ext4/inode.c:4453 [inline] __ext4_iget+0x4ff/0x3f00 fs/ext4/inode.c:4683 ext4_fill_super+0x75e5/0x96e0 fs/ext4/super.c:4831 mount_bdev+0x282/0x3b0 fs/super.c:1387 ext4_mount+0x34/0x40 fs/ext4/super.c:6581 legacy_get_tree+0xf1/0x190 fs/fs_context.c:611 vfs_get_tree+0x88/0x290 fs/super.c:1517 do_new_mount+0x2ba/0xb30 fs/namespace.c:3005 path_mount+0x671/0x1070 fs/namespace.c:3335 page last free stack trace: reset_page_owner include/linux/page_owner.h:26 [inline] free_pages_prepare mm/page_alloc.c:1471 [inline] free_pcp_prepare mm/page_alloc.c:1543 [inline] free_unref_page_prepare+0x7c8/0x7d0 mm/page_alloc.c:3533 free_unref_page_list+0x14b/0xa60 mm/page_alloc.c:3670 release_pages+0x1310/0x1370 mm/swap.c:1009 free_pages_and_swap_cache+0x8a/0xa0 mm/swap_state.c:320 tlb_batch_pages_flush mm/mmu_gather.c:49 [inline] tlb_flush_mmu_free mm/mmu_gather.c:240 [inline] tlb_flush_mmu mm/mmu_gather.c:247 [inline] tlb_finish_mmu+0x177/0x320 mm/mmu_gather.c:338 exit_mmap+0x3ef/0x6f0 mm/mmap.c:3211 __mmput+0x95/0x310 kernel/fork.c:1179 mmput+0x5b/0x170 kernel/fork.c:1202 exit_mm kernel/exit.c:552 [inline] do_exit+0xb9c/0x2ca0 kernel/exit.c:865 do_group_exit+0x141/0x310 kernel/exit.c:1000 get_signal+0x7a3/0x1630 kernel/signal.c:2896 arch_do_signal_or_restart+0xbd/0x1680 arch/x86/kernel/signal.c:867 handle_signal_work kernel/entry/common.c:148 [inline] exit_to_user_mode_loop+0xa0/0xe0 kernel/entry/common.c:172 exit_to_user_mode_prepare+0x5a/0xa0 kernel/entry/common.c:208 __syscall_exit_to_user_mode_work kernel/entry/common.c:290 [inline] syscall_exit_to_user_mode+0x26/0x160 kernel/entry/common.c:301 do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86 Memory state around the buggy address: ffff888128ac9180: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888128ac9200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff888128ac9280: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffff888128ac9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888128ac9380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ================================================================== EXT4-fs error (device loop0): __ext4_get_inode_loc:4340: comm syz-executor.0: Invalid inode table block 6286097877272143512 in block_group 0