================================================================== BUG: KASAN: out-of-bounds in ext4_xattr_set_entry+0x1159/0x3860 fs/ext4/xattr.c:1731 Read of size 18446744073709551600 at addr ffff88812e2edeb8 by task syz.0.705/3251 CPU: 0 PID: 3251 Comm: syz.0.705 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/16/2026 Call Trace: __dump_stack+0x21/0x24 lib/dump_stack.c:77 dump_stack_lvl+0x1a7/0x208 lib/dump_stack.c:118 print_address_description+0x7f/0x2c0 mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:435 [inline] kasan_report+0x100/0x140 mm/kasan/report.c:452 check_region_inline mm/kasan/generic.c:-1 [inline] kasan_check_range+0x249/0x2a0 mm/kasan/generic.c:189 memmove+0x2d/0x70 mm/kasan/shadow.c:54 ext4_xattr_set_entry+0x1159/0x3860 fs/ext4/xattr.c:1731 ext4_xattr_ibody_set+0x114/0x330 fs/ext4/xattr.c:2231 ext4_destroy_inline_data_nolock+0x20f/0x5e0 fs/ext4/inline.c:464 ext4_destroy_inline_data+0x84/0xe0 fs/ext4/inline.c:1904 ext4_writepages+0x603/0x2f00 fs/ext4/inode.c:2781 do_writepages+0x12e/0x280 mm/page-writeback.c:2380 __filemap_fdatawrite_range+0x2a0/0x350 mm/filemap.c:427 __filemap_fdatawrite mm/filemap.c:435 [inline] filemap_flush+0x23/0x30 mm/filemap.c:462 ext4_alloc_da_blocks+0x7a/0x190 fs/ext4/inode.c:3252 ext4_release_file+0x84/0x320 fs/ext4/file.c:144 __fput+0x2dc/0x730 fs/file_table.c:281 ____fput+0x15/0x20 fs/file_table.c:314 task_work_run+0x127/0x190 kernel/task_work.c:189 tracehook_notify_resume include/linux/tracehook.h:188 [inline] exit_to_user_mode_loop+0xcb/0xe0 kernel/entry/common.c:172 exit_to_user_mode_prepare+0x76/0xa0 kernel/entry/common.c:199 syscall_exit_to_user_mode+0x1d/0x40 kernel/entry/common.c:274 do_syscall_64+0x3d/0x40 arch/x86/entry/common.c:56 entry_SYSCALL_64_after_hwframe+0x61/0xcb RIP: 0033:0x7f81e7335e99 Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 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 e8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fff7d4270f8 EFLAGS: 00000246 ORIG_RAX: 00000000000001b4 RAX: 0000000000000000 RBX: 00007fff7d4271e0 RCX: 00007f81e7335e99 RDX: 0000000000000000 RSI: 000000000000001e RDI: 0000000000000003 RBP: 0000000000021850 R08: 0000000000000001 R09: 0000000000000000 R10: 0000001b2d220000 R11: 0000000000000246 R12: 00007fff7d427220 R13: 00007f81e75bdfac R14: 0000000000021908 R15: 00007f81e75bdfa0 The buggy address belongs to the page: page:ffffea0004b8bb40 refcount:3 mapcount:1 mapping:ffff88810044b590 index:0x2 pfn:0x12e2ed aops:def_blk_aops ino:0 flags: 0x400000000002203e(referenced|uptodate|dirty|lru|active|private|mappedtodisk) raw: 400000000002203e ffffea0004cea148 ffff88810dcc8030 ffff88810044b590 raw: 0000000000000002 ffff888131e56930 0000000300000000 ffff88810dcd4000 page dumped because: kasan: bad access detected page->mem_cgroup:ffff88810dcd4000 page_owner tracks the page as allocated page last allocated via order 0, migratetype Movable, gfp_mask 0x108c48(GFP_NOFS|__GFP_NOFAIL|__GFP_HARDWALL|__GFP_MOVABLE), pid 3254, ts 137411875759, free_ts 137406585651 set_page_owner include/linux/page_owner.h:35 [inline] post_alloc_hook mm/page_alloc.c:2456 [inline] prep_new_page+0x176/0x190 mm/page_alloc.c:2462 get_page_from_freelist+0x225f/0x23f0 mm/page_alloc.c:4254 __alloc_pages_nodemask+0x29a/0x640 mm/page_alloc.c:5384 __alloc_pages include/linux/gfp.h:544 [inline] __alloc_pages_node include/linux/gfp.h:557 [inline] alloc_pages_node include/linux/gfp.h:571 [inline] alloc_pages include/linux/gfp.h:590 [inline] __page_cache_alloc include/linux/pagemap.h:290 [inline] pagecache_get_page+0x63e/0x930 mm/filemap.c:1848 find_or_create_page include/linux/pagemap.h:402 [inline] grow_dev_page fs/buffer.c:976 [inline] grow_buffers fs/buffer.c:1045 [inline] __getblk_slow fs/buffer.c:1072 [inline] __getblk_gfp+0x212/0x780 fs/buffer.c:1370 sb_getblk include/linux/buffer_head.h:361 [inline] __ext4_get_inode_loc+0x45e/0xbf0 fs/ext4/inode.c:4456 __ext4_get_inode_loc_noinmem fs/ext4/inode.c:4566 [inline] __ext4_iget+0x491/0x44e0 fs/ext4/inode.c:4816 ext4_fill_super+0x6f35/0x8d90 fs/ext4/super.c:4959 mount_bdev+0x26a/0x380 fs/super.c:1442 ext4_mount+0x34/0x40 fs/ext4/super.c:6666 legacy_get_tree+0xed/0x190 fs/fs_context.c:593 vfs_get_tree+0x89/0x260 fs/super.c:1572 do_new_mount+0x25a/0xa30 fs/namespace.c:3006 path_mount+0x581/0xca0 fs/namespace.c:3336 do_mount fs/namespace.c:3349 [inline] __do_sys_mount fs/namespace.c:3557 [inline] __se_sys_mount+0x320/0x390 fs/namespace.c:3534 __x64_sys_mount+0xbf/0xd0 fs/namespace.c:3534 page last free stack trace: reset_page_owner include/linux/page_owner.h:28 [inline] free_pages_prepare mm/page_alloc.c:1349 [inline] free_pcp_prepare mm/page_alloc.c:1421 [inline] free_unref_page_prepare+0x2b7/0x2d0 mm/page_alloc.c:3336 free_unref_page_list+0x129/0x9c0 mm/page_alloc.c:3443 release_pages+0xe41/0xe90 mm/swap.c:1103 free_pages_and_swap_cache+0x86/0xa0 mm/swap_state.c:356 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+0x17e/0x310 mm/mmu_gather.c:326 unmap_region+0x355/0x3c0 mm/mmap.c:2811 __do_munmap+0x63c/0x850 mm/mmap.c:3041 __vm_munmap mm/mmap.c:3094 [inline] __do_sys_munmap mm/mmap.c:3120 [inline] __se_sys_munmap+0x12c/0x1c0 mm/mmap.c:3116 __x64_sys_munmap+0x5b/0x70 mm/mmap.c:3116 do_syscall_64+0x31/0x40 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x61/0xcb Memory state around the buggy address: ffff88812e2edd80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88812e2ede00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88812e2ede80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffff88812e2edf00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88812e2edf80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ================================================================== EXT4-fs error (device loop0): ext4_mb_generate_buddy:824: group 0, block bitmap and bg descriptor inconsistent: 25 vs 281 free clusters EXT4-fs (loop0): Delayed block allocation failed for inode 15 at logical offset 0 with max blocks 1 with error 28 EXT4-fs (loop0): This should not happen!! Data will be lost EXT4-fs (loop0): Total free blocks count 0 EXT4-fs (loop0): Free/Dirty block details EXT4-fs (loop0): free_blocks=4096 EXT4-fs (loop0): dirty_blocks=80 EXT4-fs (loop0): Block reservation details EXT4-fs (loop0): i_reserved_data_blocks=5