syz.3.5: attempt to access beyond end of device loop3: rw=524288, sector=720, nr_sectors = 16 limit=16 syz.3.5: attempt to access beyond end of device loop3: rw=524288, sector=525144, nr_sectors = 16 limit=16 ================================================================== BUG: KASAN: slab-out-of-bounds in memcpy_to_page include/linux/highmem.h:427 [inline] BUG: KASAN: slab-out-of-bounds in z_erofs_transform_plain+0x38c/0x460 fs/erofs/decompressor.c:346 Read of size 4095 at addr ffff888024ec0400 by task syz.3.5/5899 CPU: 1 PID: 5899 Comm: syz.3.5 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/18/2025 Call Trace: dump_stack_lvl+0x16c/0x230 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:364 [inline] print_report+0xac/0x220 mm/kasan/report.c:468 kasan_report+0x117/0x150 mm/kasan/report.c:581 check_region_inline mm/kasan/generic.c:-1 [inline] kasan_check_range+0x288/0x290 mm/kasan/generic.c:187 __asan_memcpy+0x29/0x70 mm/kasan/shadow.c:105 memcpy_to_page include/linux/highmem.h:427 [inline] z_erofs_transform_plain+0x38c/0x460 fs/erofs/decompressor.c:346 z_erofs_decompress_pcluster fs/erofs/zdata.c:1296 [inline] z_erofs_decompress_queue+0x16fb/0x2660 fs/erofs/zdata.c:1377 z_erofs_runqueue+0x18a3/0x19d0 fs/erofs/zdata.c:1774 z_erofs_readahead+0xa7c/0xd50 fs/erofs/zdata.c:1903 read_pages+0x177/0x840 mm/readahead.c:160 page_cache_ra_unbounded+0x692/0x770 mm/readahead.c:269 do_page_cache_ra mm/readahead.c:299 [inline] force_page_cache_ra+0x2c1/0x320 mm/readahead.c:330 force_page_cache_readahead mm/internal.h:175 [inline] generic_fadvise+0x44f/0x730 mm/fadvise.c:106 vfs_fadvise mm/fadvise.c:185 [inline] ksys_fadvise64_64 mm/fadvise.c:199 [inline] __do_sys_fadvise64 mm/fadvise.c:214 [inline] __se_sys_fadvise64 mm/fadvise.c:212 [inline] __x64_sys_fadvise64+0x140/0x180 mm/fadvise.c:212 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7fc03a38eba9 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fc03b1eb038 EFLAGS: 00000246 ORIG_RAX: 00000000000000dd RAX: ffffffffffffffda RBX: 00007fc03a5d5fa0 RCX: 00007fc03a38eba9 RDX: 000000000000ff39 RSI: 0000000000000003 RDI: 0000000000000004 RBP: 00007fc03a411e19 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000003 R11: 0000000000000246 R12: 0000000000000000 R13: 00007fc03a5d6038 R14: 00007fc03a5d5fa0 R15: 00007ffdc48330e8 The buggy address belongs to the physical page: page:ffffea000093b000 refcount:2 mapcount:0 mapping:ffff88805d8a07c8 index:0x1 pfn:0x24ec0 memcg:ffff88807d7f8000 aops:z_erofs_cache_aops ino:0 flags: 0xfff40000008028(uptodate|lru|private|node=0|zone=1|lastcpupid=0x7ff) page_type: 0xffffffff() raw: 00fff40000008028 ffffea0000948d48 ffffea00008fa088 ffff88805d8a07c8 raw: 0000000000000001 ffff88805c2e85e0 00000002ffffffff ffff88807d7f8000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x192840(GFP_NOWAIT|__GFP_IO|__GFP_NOWARN|__GFP_NORETRY|__GFP_NOMEMALLOC|__GFP_HARDWALL), pid 5905, tgid 5898 (syz.3.5), ts 82665268255, free_ts 82544135652 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x1cd/0x210 mm/page_alloc.c:1554 prep_new_page mm/page_alloc.c:1561 [inline] get_page_from_freelist+0x195c/0x19f0 mm/page_alloc.c:3191 __alloc_pages+0x1e3/0x460 mm/page_alloc.c:4457 z_erofs_bind_cache fs/erofs/zdata.c:605 [inline] z_erofs_pcluster_begin fs/erofs/zdata.c:889 [inline] z_erofs_do_read_page+0x20c0/0x3680 fs/erofs/zdata.c:1024 z_erofs_read_folio+0x213/0x540 fs/erofs/zdata.c:1854 filemap_read_folio+0x167/0x760 mm/filemap.c:2420 do_read_cache_folio+0x470/0x7e0 mm/filemap.c:3789 erofs_bread+0x16f/0x630 fs/erofs/data.c:48 erofs_find_target_block fs/erofs/namei.c:103 [inline] erofs_namei+0x28c/0xf00 fs/erofs/namei.c:177 erofs_lookup+0x135/0x310 fs/erofs/namei.c:206 lookup_open fs/namei.c:3466 [inline] open_last_lookups fs/namei.c:3556 [inline] path_openat+0x10b8/0x3190 fs/namei.c:3786 do_filp_open+0x1c5/0x3d0 fs/namei.c:3816 do_sys_openat2+0x12c/0x1c0 fs/open.c:1419 do_sys_open fs/open.c:1434 [inline] __do_sys_openat fs/open.c:1450 [inline] __se_sys_openat fs/open.c:1445 [inline] __x64_sys_openat+0x139/0x160 fs/open.c:1445 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1154 [inline] free_unref_page_prepare+0x7ce/0x8e0 mm/page_alloc.c:2336 free_unref_page+0x32/0x2e0 mm/page_alloc.c:2429 discard_slab mm/slub.c:2127 [inline] __unfreeze_partials+0x1cf/0x210 mm/slub.c:2667 put_cpu_partial+0x17c/0x250 mm/slub.c:2743 __slab_free+0x31d/0x410 mm/slub.c:3700 qlink_free mm/kasan/quarantine.c:166 [inline] qlist_free_all+0x75/0xe0 mm/kasan/quarantine.c:185 kasan_quarantine_reduce+0x143/0x160 mm/kasan/quarantine.c:292 __kasan_slab_alloc+0x22/0x80 mm/kasan/common.c:305 kasan_slab_alloc include/linux/kasan.h:188 [inline] slab_post_alloc_hook+0x6e/0x4d0 mm/slab.h:767 slab_alloc_node mm/slub.c:3495 [inline] kmem_cache_alloc_node+0x150/0x330 mm/slub.c:3540 __alloc_skb+0x108/0x2c0 net/core/skbuff.c:640 alloc_skb include/linux/skbuff.h:1284 [inline] mld_newpack+0x143/0xbf0 net/ipv6/mcast.c:1743 add_grhead+0x5a/0x2a0 net/ipv6/mcast.c:1854 add_grec+0x13ad/0x1660 net/ipv6/mcast.c:1992 mld_send_initial_cr+0xed/0x240 net/ipv6/mcast.c:2237 ipv6_mc_dad_complete+0x88/0x210 net/ipv6/mcast.c:2248 Memory state around the buggy address: ffff888024ec0f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888024ec1000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff888024ec1080: 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc 00 ^ ffff888024ec1100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888024ec1180: 00 00 00 00 00 00 fc fc fc fc fc fc fc fc 00 00 ==================================================================