================================================================== BUG: KASAN: slab-out-of-bounds in iov_iter_revert+0x1da/0x5f0 lib/iov_iter.c:633 Read of size 4 at addr ffff88805702fd78 by task kworker/u8:5/13790 CPU: 0 UID: 0 PID: 13790 Comm: kworker/u8:5 Not tainted 6.15.0-rc3-syzkaller-00094-g02ddfb981de8 #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2025 Workqueue: events_unbound netfs_write_collection_worker Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:408 [inline] print_report+0xb4/0x290 mm/kasan/report.c:521 kasan_report+0x118/0x150 mm/kasan/report.c:634 iov_iter_revert+0x1da/0x5f0 lib/iov_iter.c:633 netfs_retry_write_stream fs/netfs/write_retry.c:44 [inline] netfs_retry_writes+0x1645/0x1840 fs/netfs/write_retry.c:231 netfs_collect_write_results fs/netfs/write_collect.c:352 [inline] netfs_write_collection_worker+0x2007/0x2bd0 fs/netfs/write_collect.c:374 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xade/0x17a0 kernel/workqueue.c:3319 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3400 kthread+0x711/0x8a0 kernel/kthread.c:464 ret_from_fork+0x4e/0x80 arch/x86/kernel/process.c:153 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Allocated by task 6022: kasan_save_stack mm/kasan/common.c:47 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:68 poison_kmalloc_redzone mm/kasan/common.c:377 [inline] __kasan_kmalloc+0x93/0xb0 mm/kasan/common.c:394 kasan_kmalloc include/linux/kasan.h:260 [inline] __kmalloc_cache_noprof+0x230/0x3d0 mm/slub.c:4372 kmalloc_noprof include/linux/slab.h:905 [inline] kzalloc_noprof include/linux/slab.h:1039 [inline] ref_tracker_alloc+0x133/0x460 lib/ref_tracker.c:203 __netdev_tracker_alloc include/linux/netdevice.h:4331 [inline] netdev_hold include/linux/netdevice.h:4360 [inline] dst_init+0xd9/0x450 net/core/dst.c:52 dst_alloc+0x12a/0x170 net/core/dst.c:93 ip6_dst_alloc net/ipv6/route.c:342 [inline] icmp6_dst_alloc+0x75/0x420 net/ipv6/route.c:3315 mld_sendpack+0x678/0xd80 net/ipv6/mcast.c:1857 mld_dad_work+0x45/0x520 net/ipv6/mcast.c:2308 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xade/0x17a0 kernel/workqueue.c:3319 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3400 kthread+0x711/0x8a0 kernel/kthread.c:464 ret_from_fork+0x4e/0x80 arch/x86/kernel/process.c:153 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 The buggy address belongs to the object at ffff88805702fd40 which belongs to the cache kmalloc-32 of size 32 The buggy address is located 24 bytes to the right of allocated 32-byte region [ffff88805702fd40, ffff88805702fd60) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x5702f anon flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) page_type: f5(slab) raw: 00fff00000000000 ffff88801a441780 0000000000000000 dead000000000001 raw: 0000000000000000 0000000000400040 00000000f5000000 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 0x52800(GFP_NOWAIT|__GFP_NORETRY|__GFP_COMP), pid 7796, tgid 7796 (kworker/u8:12), ts 283236939364, free_ts 283017214824 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1d8/0x230 mm/page_alloc.c:1718 prep_new_page mm/page_alloc.c:1726 [inline] get_page_from_freelist+0x21ce/0x22b0 mm/page_alloc.c:3688 __alloc_frozen_pages_noprof+0x181/0x370 mm/page_alloc.c:4970 alloc_pages_mpol+0x232/0x4a0 mm/mempolicy.c:2301 alloc_slab_page mm/slub.c:2468 [inline] allocate_slab+0x8a/0x3b0 mm/slub.c:2632 new_slab mm/slub.c:2686 [inline] ___slab_alloc+0xbfc/0x1480 mm/slub.c:3872 __slab_alloc mm/slub.c:3962 [inline] __slab_alloc_node mm/slub.c:4037 [inline] slab_alloc_node mm/slub.c:4198 [inline] __kmalloc_cache_noprof+0x296/0x3d0 mm/slub.c:4367 kmalloc_noprof include/linux/slab.h:905 [inline] slab_free_hook mm/slub.c:2350 [inline] slab_free mm/slub.c:4656 [inline] kmem_cache_free+0x169/0x3f0 mm/slub.c:4758 io_req_caches_free+0xa4/0x110 io_uring/io_uring.c:2716 io_ring_exit_work+0x3d8/0x880 io_uring/io_uring.c:2916 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xade/0x17a0 kernel/workqueue.c:3319 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3400 kthread+0x711/0x8a0 kernel/kthread.c:464 ret_from_fork+0x4e/0x80 arch/x86/kernel/process.c:153 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 page last free pid 5186 tgid 5186 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1262 [inline] __free_frozen_pages+0xb0e/0xcd0 mm/page_alloc.c:2725 pagetable_free include/linux/mm.h:3019 [inline] pagetable_dtor_free include/linux/mm.h:3117 [inline] __tlb_remove_table+0x2d2/0x3b0 include/asm-generic/tlb.h:215 __tlb_remove_table_free mm/mmu_gather.c:227 [inline] tlb_remove_table_rcu+0x85/0x100 mm/mmu_gather.c:290 rcu_do_batch kernel/rcu/tree.c:2568 [inline] rcu_core+0xca8/0x1710 kernel/rcu/tree.c:2824 handle_softirqs+0x286/0x870 kernel/softirq.c:579 __do_softirq kernel/softirq.c:613 [inline] invoke_softirq kernel/softirq.c:453 [inline] __irq_exit_rcu+0xca/0x1f0 kernel/softirq.c:680 irq_exit_rcu+0x9/0x30 kernel/softirq.c:696 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1049 [inline] sysvec_apic_timer_interrupt+0xa6/0xc0 arch/x86/kernel/apic/apic.c:1049 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:702 Memory state around the buggy address: ffff88805702fc00: 00 00 00 00 fc fc fc fc 00 00 00 00 fc fc fc fc ffff88805702fc80: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc >ffff88805702fd00: fa fb fb fb fc fc fc fc 00 00 00 00 fc fc fc fc ^ ffff88805702fd80: 00 00 00 00 fc fc fc fc fa fb fb fb fc fc fc fc ffff88805702fe00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc ==================================================================