================================================================== BUG: KASAN: use-after-free in instrument_atomic_read_write include/linux/instrumented.h:102 [inline] BUG: KASAN: use-after-free in atomic_try_cmpxchg_acquire include/linux/atomic/atomic-instrumented.h:541 [inline] BUG: KASAN: use-after-free in queued_spin_lock include/asm-generic/qspinlock.h:111 [inline] BUG: KASAN: use-after-free in do_raw_spin_lock include/linux/spinlock.h:187 [inline] BUG: KASAN: use-after-free in __raw_spin_lock_bh include/linux/spinlock_api_smp.h:127 [inline] BUG: KASAN: use-after-free in _raw_spin_lock_bh+0x81/0xe0 kernel/locking/spinlock.c:178 Write of size 4 at addr ffff88812d1bc914 by task kworker/u4:3/420 CPU: 1 PID: 420 Comm: kworker/u4:3 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025 Workqueue: netns cleanup_net Call Trace: __dump_stack+0x21/0x24 lib/dump_stack.c:88 dump_stack_lvl+0xee/0x150 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+0x280/0x290 mm/kasan/generic.c:189 __kasan_check_write+0x14/0x20 mm/kasan/shadow.c:37 instrument_atomic_read_write include/linux/instrumented.h:102 [inline] atomic_try_cmpxchg_acquire include/linux/atomic/atomic-instrumented.h:541 [inline] queued_spin_lock include/asm-generic/qspinlock.h:111 [inline] do_raw_spin_lock include/linux/spinlock.h:187 [inline] __raw_spin_lock_bh include/linux/spinlock_api_smp.h:127 [inline] _raw_spin_lock_bh+0x81/0xe0 kernel/locking/spinlock.c:178 spin_lock_bh include/linux/spinlock.h:356 [inline] __ip6_del_rt+0x8f/0x150 net/ipv6/route.c:3912 ip6_del_rt+0xb0/0xf0 net/ipv6/route.c:3928 __remove_nexthop_fib+0x1f7/0x270 net/ipv4/nexthop.c:1861 __remove_nexthop net/ipv4/nexthop.c:1869 [inline] remove_nexthop+0x73/0x500 net/ipv4/nexthop.c:1895 remove_nh_grp_entry net/ipv4/nexthop.c:1751 [inline] remove_nexthop_from_groups+0x22f/0x1210 net/ipv4/nexthop.c:1816 __remove_nexthop net/ipv4/nexthop.c:1880 [inline] remove_nexthop+0x3b6/0x500 net/ipv4/nexthop.c:1895 flush_all_nexthops net/ipv4/nexthop.c:2404 [inline] nexthop_net_exit_batch+0x76/0x110 net/ipv4/nexthop.c:3730 ops_exit_list net/core/net_namespace.c:177 [inline] cleanup_net+0x710/0xc60 net/core/net_namespace.c:640 process_one_work+0x71f/0xc40 kernel/workqueue.c:2292 worker_thread+0xa26/0x11e0 kernel/workqueue.c:2439 kthread+0x281/0x320 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 Allocated by task 566: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4b/0x70 mm/kasan/common.c:52 kasan_save_alloc_info+0x25/0x30 mm/kasan/generic.c:505 ____kasan_kmalloc mm/kasan/common.c:374 [inline] __kasan_kmalloc+0x95/0xb0 mm/kasan/common.c:383 kasan_kmalloc include/linux/kasan.h:211 [inline] kmalloc_trace+0x40/0xb0 mm/slab_common.c:1031 kmalloc include/linux/slab.h:563 [inline] kzalloc include/linux/slab.h:699 [inline] fib6_net_init+0x23d/0x8c0 net/ipv6/ip6_fib.c:2389 ops_init+0x1c8/0x4a0 net/core/net_namespace.c:138 setup_net+0x4f1/0xdc0 net/core/net_namespace.c:336 copy_net_ns+0x35a/0x5c0 net/core/net_namespace.c:508 create_new_namespaces+0x3a2/0x660 kernel/nsproxy.c:110 unshare_nsproxy_namespaces+0x120/0x170 kernel/nsproxy.c:226 ksys_unshare+0x4ac/0x7b0 kernel/fork.c:3277 __do_sys_unshare kernel/fork.c:3348 [inline] __se_sys_unshare kernel/fork.c:3346 [inline] __x64_sys_unshare+0x38/0x40 kernel/fork.c:3346 x64_sys_call+0x767/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:273 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 Freed by task 420: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4b/0x70 mm/kasan/common.c:52 kasan_save_free_info+0x31/0x50 mm/kasan/generic.c:516 ____kasan_slab_free+0x132/0x180 mm/kasan/common.c:236 __kasan_slab_free+0x11/0x20 mm/kasan/common.c:244 kasan_slab_free include/linux/kasan.h:177 [inline] slab_free_hook mm/slub.c:1729 [inline] slab_free_freelist_hook+0xc2/0x190 mm/slub.c:1755 slab_free mm/slub.c:3687 [inline] __kmem_cache_free+0xb7/0x160 mm/slub.c:3700 kfree+0x6f/0xf0 mm/slab_common.c:988 fib6_free_table net/ipv6/ip6_fib.c:216 [inline] fib6_net_exit+0x270/0x300 net/ipv6/ip6_fib.c:2443 ops_exit_list net/core/net_namespace.c:172 [inline] cleanup_net+0x68d/0xc60 net/core/net_namespace.c:640 process_one_work+0x71f/0xc40 kernel/workqueue.c:2292 worker_thread+0xa26/0x11e0 kernel/workqueue.c:2439 kthread+0x281/0x320 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 The buggy address belongs to the object at ffff88812d1bc900 which belongs to the cache kmalloc-128 of size 128 The buggy address is located 20 bytes inside of 128-byte region [ffff88812d1bc900, ffff88812d1bc980) The buggy address belongs to the physical page: page:ffffea0004b46f00 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x12d1bc flags: 0x4000000000000200(slab|zone=1) raw: 4000000000000200 ffffea0004321800 dead000000000004 ffff8881000418c0 raw: 0000000000000000 0000000000100010 00000001ffffffff 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 0x112a20(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_HARDWALL), pid 559, tgid 559 (syz-executor), ts 47959829216, free_ts 47957436837 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x1d0/0x1f0 mm/page_alloc.c:2532 prep_new_page mm/page_alloc.c:2539 [inline] get_page_from_freelist+0x2e63/0x2ef0 mm/page_alloc.c:4328 __alloc_pages+0x235/0x4b0 mm/page_alloc.c:5614 alloc_slab_page include/linux/gfp.h:-1 [inline] allocate_slab mm/slub.c:1944 [inline] new_slab+0xec/0x4b0 mm/slub.c:1997 ___slab_alloc+0x6bd/0xb20 mm/slub.c:3154 __slab_alloc+0x5e/0xa0 mm/slub.c:3240 slab_alloc_node mm/slub.c:3325 [inline] __kmem_cache_alloc_node+0x1b1/0x260 mm/slub.c:3398 kmalloc_trace+0x29/0xb0 mm/slab_common.c:1026 kmalloc include/linux/slab.h:563 [inline] __hw_addr_create net/core/dev_addr_lists.c:60 [inline] __hw_addr_add_ex+0x1f7/0x770 net/core/dev_addr_lists.c:118 __hw_addr_add net/core/dev_addr_lists.c:135 [inline] dev_addr_init+0x138/0x210 net/core/dev_addr_lists.c:558 alloc_netdev_mqs+0x296/0xf80 net/core/dev.c:10748 rtnl_create_link+0x319/0xb10 net/core/rtnetlink.c:3295 rtnl_newlink_create net/core/rtnetlink.c:3412 [inline] __rtnl_newlink net/core/rtnetlink.c:3642 [inline] rtnl_newlink+0x13b1/0x2030 net/core/rtnetlink.c:3655 rtnetlink_rcv_msg+0x9f4/0xcf0 net/core/rtnetlink.c:6153 netlink_rcv_skb+0x1f2/0x440 net/netlink/af_netlink.c:2511 rtnetlink_rcv+0x1c/0x20 net/core/rtnetlink.c:6171 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1459 [inline] free_pcp_prepare mm/page_alloc.c:1532 [inline] free_unref_page_prepare+0x742/0x750 mm/page_alloc.c:3384 free_unref_page+0x33/0x390 mm/page_alloc.c:3479 free_the_page mm/page_alloc.c:754 [inline] __free_pages+0x67/0x100 mm/page_alloc.c:5703 free_pages+0x82/0x90 mm/page_alloc.c:5714 tlb_batch_list_free mm/mmu_gather.c:75 [inline] tlb_finish_mmu+0x2ba/0x370 mm/mmu_gather.c:364 exit_mmap+0x31f/0x750 mm/mmap.c:3262 __mmput+0x93/0x320 kernel/fork.c:1200 mmput+0x47/0x60 kernel/fork.c:1222 exit_mm kernel/exit.c:565 [inline] do_exit+0x95f/0x2410 kernel/exit.c:867 do_group_exit+0x210/0x2d0 kernel/exit.c:1022 get_signal+0x13b5/0x1520 kernel/signal.c:2871 arch_do_signal_or_restart+0xb0/0x1030 arch/x86/kernel/signal.c:871 exit_to_user_mode_loop+0x7a/0xb0 kernel/entry/common.c:174 exit_to_user_mode_prepare+0x5a/0xa0 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:87 Memory state around the buggy address: ffff88812d1bc800: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88812d1bc880: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff88812d1bc900: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff88812d1bc980: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88812d1bca00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc fc ================================================================== device bridge_slave_1 left promiscuous mode bridge0: port 2(bridge_slave_1) entered disabled state device bridge_slave_0 left promiscuous mode bridge0: port 1(bridge_slave_0) entered disabled state device veth1_macvtap left promiscuous mode device veth0_vlan left promiscuous mode