bond0 (unregistering): (slave bond_slave_1): Releasing backup interface bond0 (unregistering): (slave bond_slave_0): Releasing backup interface bond0 (unregistering): Released all slaves ================================================================== BUG: KASAN: use-after-free in mini_qdisc_pair_swap+0x19d/0x1f0 net/sched/sch_generic.c:1553 Read of size 8 at addr ffff88807e658000 by task kworker/u4:3/22812 CPU: 0 PID: 22812 Comm: kworker/u4:3 Not tainted 6.5.0-rc3-syzkaller-00699-g88efedf517e6 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2023 Workqueue: netns cleanup_net Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd9/0x1b0 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:364 [inline] print_report+0xc4/0x620 mm/kasan/report.c:475 kasan_report+0xda/0x110 mm/kasan/report.c:588 mini_qdisc_pair_swap+0x19d/0x1f0 net/sched/sch_generic.c:1553 tcf_chain_head_change_item net/sched/cls_api.c:493 [inline] tcf_chain0_head_change_cb_del+0x19c/0x3d0 net/sched/cls_api.c:940 tcf_block_put_ext.part.0+0x30/0x2e0 net/sched/cls_api.c:1505 tcf_block_put_ext+0x2e/0x40 net/sched/cls_api.c:1503 clsact_destroy+0x283/0x990 net/sched/sch_ingress.c:300 __qdisc_destroy+0xc4/0x450 net/sched/sch_generic.c:1063 qdisc_put+0xd1/0xf0 net/sched/sch_generic.c:1090 shutdown_scheduler_queue+0xa5/0x160 net/sched/sch_generic.c:1143 dev_shutdown+0x17e/0x430 net/sched/sch_generic.c:1477 unregister_netdevice_many_notify+0x5bd/0x1a20 net/core/dev.c:10916 unregister_netdevice_many net/core/dev.c:10982 [inline] default_device_exit_batch+0x584/0x740 net/core/dev.c:11442 ops_exit_list+0x125/0x170 net/core/net_namespace.c:175 cleanup_net+0x505/0xb20 net/core/net_namespace.c:614 process_one_work+0xaa2/0x16f0 kernel/workqueue.c:2597 worker_thread+0x687/0x1110 kernel/workqueue.c:2748 kthread+0x33a/0x430 kernel/kthread.c:389 ret_from_fork+0x2c/0x70 arch/x86/kernel/process.c:145 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:296 RIP: 0000:0x0 Code: Unable to access opcode bytes at 0xffffffffffffffd6. RSP: 0000:0000000000000000 EFLAGS: 00000000 ORIG_RAX: 0000000000000000 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 The buggy address belongs to the physical page: page:ffffea0001f99600 refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x7e658 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) page_type: 0xffffffff() raw: 00fff00000000000 dead000000000100 dead000000000122 0000000000000000 raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as freed page last allocated via order 0, migratetype Unmovable, gfp_mask 0x506dc2(GFP_HIGHUSER|__GFP_NOWARN|__GFP_RETRY_MAYFAIL|__GFP_ZERO|__GFP_ACCOUNT), pid 24864, tgid 24858 (syz-executor.5), ts 667614762861, free_ts 668062701970 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x2d2/0x350 mm/page_alloc.c:1570 prep_new_page mm/page_alloc.c:1577 [inline] get_page_from_freelist+0x10a9/0x31e0 mm/page_alloc.c:3221 __alloc_pages+0x1d0/0x4a0 mm/page_alloc.c:4477 alloc_pages+0x1a9/0x270 mm/mempolicy.c:2279 vm_area_alloc_pages mm/vmalloc.c:3059 [inline] __vmalloc_area_node mm/vmalloc.c:3135 [inline] __vmalloc_node_range+0xa6e/0x1540 mm/vmalloc.c:3316 __bpf_map_area_alloc+0xea/0x180 kernel/bpf/syscall.c:307 prealloc_init kernel/bpf/hashtab.c:322 [inline] htab_map_alloc+0xb56/0x1760 kernel/bpf/hashtab.c:565 map_create+0x548/0x1930 kernel/bpf/syscall.c:1208 __sys_bpf+0x9f8/0x4ec0 kernel/bpf/syscall.c:5327 __do_sys_bpf kernel/bpf/syscall.c:5449 [inline] __se_sys_bpf kernel/bpf/syscall.c:5447 [inline] __x64_sys_bpf+0x78/0xc0 kernel/bpf/syscall.c:5447 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1161 [inline] free_unref_page_prepare+0x508/0xb90 mm/page_alloc.c:2348 free_unref_page+0x33/0x3b0 mm/page_alloc.c:2443 vfree+0x181/0x7a0 mm/vmalloc.c:2842 kvfree+0x33/0x50 mm/util.c:648 prealloc_destroy kernel/bpf/hashtab.c:375 [inline] htab_map_free+0x8ad/0xb20 kernel/bpf/hashtab.c:1540 bpf_map_free_deferred+0x192/0x3c0 kernel/bpf/syscall.c:700 process_one_work+0xaa2/0x16f0 kernel/workqueue.c:2597 worker_thread+0x687/0x1110 kernel/workqueue.c:2748 kthread+0x33a/0x430 kernel/kthread.c:389 ret_from_fork+0x2c/0x70 arch/x86/kernel/process.c:145 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:296 Memory state around the buggy address: ffff88807e657f00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff88807e657f80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff88807e658000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff88807e658080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff88807e658100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================