EXT4-fs error (device loop9): ext4_read_block_bitmap_nowait:477: comm syz.9.1542: Invalid block bitmap block 4294967295 in block_group 0 EXT4-fs (loop9): Remounting filesystem read-only ================================================================== BUG: KASAN: out-of-bounds in ext4_xattr_set_entry+0xb02/0x2230 fs/ext4/xattr.c:1708 Read of size 18446744073709551600 at addr ffff88811b00f2b8 by task syz.9.1542/5670 CPU: 0 PID: 5670 Comm: syz.9.1542 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/25/2026 Call Trace: __dump_stack+0x21/0x24 lib/dump_stack.c:88 dump_stack_lvl+0x110/0x170 lib/dump_stack.c:106 print_address_description+0x71/0x200 mm/kasan/report.c:316 print_report+0x4a/0x60 mm/kasan/report.c:420 kasan_report+0x122/0x150 mm/kasan/report.c:524 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+0xb02/0x2230 fs/ext4/xattr.c:1708 ext4_xattr_ibody_set+0x25b/0x720 fs/ext4/xattr.c:2215 ext4_destroy_inline_data_nolock+0x234/0x5e0 fs/ext4/inline.c:468 ext4_convert_inline_data_to_extent fs/ext4/inline.c:620 [inline] ext4_try_to_write_inline_data+0x764/0x1330 fs/ext4/inline.c:761 ext4_write_begin+0x1f8/0xfc0 fs/ext4/inode.c:1207 ext4_da_write_begin+0x3ed/0x880 fs/ext4/inode.c:3003 generic_perform_write+0x32d/0x740 mm/filemap.c:3915 ext4_buffered_write_iter+0x38f/0x690 fs/ext4/file.c:285 ext4_file_write_iter+0x4b2/0x1540 fs/ext4/file.c:-1 do_iter_readv_writev fs/read_write.c:-1 [inline] do_iter_write+0x65a/0xb30 fs/read_write.c:861 vfs_writev+0x339/0x5f0 fs/read_write.c:934 do_pwritev fs/read_write.c:1031 [inline] __do_sys_pwritev2 fs/read_write.c:1090 [inline] __se_sys_pwritev2+0x17d/0x290 fs/read_write.c:1081 __x64_sys_pwritev2+0xbf/0xd0 fs/read_write.c:1081 x64_sys_call+0x2d6/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:329 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7f08e4f9de99 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:00007f08e5e59028 EFLAGS: 00000246 ORIG_RAX: 0000000000000148 RAX: ffffffffffffffda RBX: 00007f08e5225fa0 RCX: 00007f08e4f9de99 RDX: 0000000000000001 RSI: 00002000000000c0 RDI: 000000000000000b RBP: 00007f08e5033eaf R08: 0000000000000000 R09: 0000000000000000 R10: 00000000007ffffe R11: 0000000000000246 R12: 0000000000000000 R13: 00007f08e5226038 R14: 00007f08e5225fa0 R15: 00007ffe44136fe8 The buggy address belongs to the physical page: page:ffffea00046c03c0 refcount:3 mapcount:1 mapping:ffff88810b72ba50 index:0x2 pfn:0x11b00f memcg:ffff8881135f9d40 aops:def_blk_aops ino:700009 flags: 0x660000000002205e(referenced|uptodate|dirty|lru|workingset|private|mappedtodisk|zone=1) raw: 660000000002205e ffff8881135eedd0 ffffea0004afc008 ffff88810b72ba50 raw: 0000000000000002 ffff888117a6a0a8 0000000300000000 ffff8881135f9d40 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x152c40(GFP_NOFS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_HARDWALL), pid 5670, tgid 5666 (syz.9.1542), ts 319612770700, free_ts 319257878947 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0x1f5/0x210 mm/page_alloc.c:2672 prep_new_page+0x1c/0x110 mm/page_alloc.c:2679 get_page_from_freelist+0x2ca9/0x2d20 mm/page_alloc.c:4586 __alloc_pages+0x1fa/0x610 mm/page_alloc.c:5930 __folio_alloc+0x12/0x40 mm/page_alloc.c:5963 __folio_alloc_node include/linux/gfp.h:245 [inline] folio_alloc include/linux/gfp.h:274 [inline] filemap_alloc_folio include/linux/pagemap.h:515 [inline] page_cache_ra_unbounded+0x24d/0x850 mm/readahead.c:260 do_page_cache_ra mm/readahead.c:313 [inline] page_cache_ra_order+0xb0c/0xe50 mm/readahead.c:584 do_sync_mmap_readahead+0x8a4/0xb20 mm/filemap.c:3203 filemap_fault+0x3e3/0x1370 mm/filemap.c:3300 __do_fault mm/memory.c:4376 [inline] do_read_fault mm/memory.c:4751 [inline] do_fault+0x19de/0x1e30 mm/memory.c:4887 handle_pte_fault mm/memory.c:5183 [inline] __handle_mm_fault mm/memory.c:5325 [inline] handle_mm_fault+0x1363/0x26b0 mm/memory.c:5465 faultin_page mm/gup.c:1026 [inline] __get_user_pages+0x34b/0xdb0 mm/gup.c:1250 populate_vma_page_range mm/gup.c:1607 [inline] __mm_populate+0x2ea/0x430 mm/gup.c:1721 mm_populate include/linux/mm.h:3148 [inline] vm_mmap_pgoff+0x271/0x3f0 mm/util.c:530 ksys_mmap_pgoff+0x161/0x1d0 mm/mmap.c:1537 __do_sys_mmap arch/x86/kernel/sys_x86_64.c:93 [inline] __se_sys_mmap arch/x86/kernel/sys_x86_64.c:86 [inline] __x64_sys_mmap+0xfa/0x110 arch/x86/kernel/sys_x86_64.c:86 page last free stack trace: reset_page_owner include/linux/page_owner.h:26 [inline] free_pages_prepare mm/page_alloc.c:1580 [inline] free_pcp_prepare mm/page_alloc.c:1654 [inline] free_unref_page_prepare+0x80c/0x820 mm/page_alloc.c:3621 free_unref_page+0x93/0x530 mm/page_alloc.c:3719 free_the_page mm/page_alloc.c:863 [inline] __free_pages+0x67/0x100 mm/page_alloc.c:6020 free_pages+0x82/0x90 mm/page_alloc.c:6031 tlb_batch_list_free mm/mmu_gather.c:75 [inline] tlb_finish_mmu+0x2d1/0x380 mm/mmu_gather.c:364 exit_mmap+0x41d/0xc10 mm/mmap.c:3384 __mmput+0x92/0x340 kernel/fork.c:1319 mmput+0x4b/0x150 kernel/fork.c:1343 exit_mm kernel/exit.c:569 [inline] do_exit+0xa51/0x2850 kernel/exit.c:874 do_group_exit+0x21b/0x2e0 kernel/exit.c:1030 get_signal+0x167c/0x1700 kernel/signal.c:2895 arch_do_signal_or_restart+0xd1/0x11c0 arch/x86/kernel/signal.c:871 exit_to_user_mode_loop+0x7a/0xb0 kernel/entry/common.c:174 exit_to_user_mode_prepare+0x87/0xd0 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:82 Memory state around the buggy address: ffff88811b00f180: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88811b00f200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88811b00f280: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffff88811b00f300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88811b00f380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================