make -C tools/testing/selftests TARGETS=net TEST_PROGS=amt.sh TEST_GEN_PROOGS="" run_tests make: Entering directory '/home/virtme/testing-3/tools/testing/selftests' make[1]: Entering directory '/home/virtme/testing-3/tools/testing/selftests/net' make[1]: Nothing to be done for 'all'. make[1]: Leaving directory '/home/virtme/testing-3/tools/testing/selftests/net' make[1]: Entering directory '/home/virtme/testing-3/tools/testing/selftests/net' TAP version 13 1..1 # timeout set to 6000 # selftests: net: amt.sh [ 453.426873][ T3726] br0: port 1(gw_l) entered blocking state [ 453.427319][ T3726] br0: port 1(gw_l) entered disabled state [ 453.427680][ T3726] gw_l: entered allmulticast mode [ 453.428984][ T3726] gw_l: entered promiscuous mode [ 453.431413][ T3726] br0: port 1(gw_l) entered blocking state [ 453.431785][ T3726] br0: port 1(gw_l) entered forwarding state [ 453.919257][ T3728] br0: port 2(amtg) entered blocking state [ 453.919646][ T3728] br0: port 2(amtg) entered disabled state [ 453.920051][ T3728] amtg: entered allmulticast mode [ 453.921403][ T3728] amtg: entered promiscuous mode [ 455.787640][ T3739] br0: port 2(amtg) entered blocking state [ 455.788023][ T3739] br0: port 2(amtg) entered forwarding state [ 456.633666][ T3745] amtr: entered allmulticast mode [ 456.634190][ T3745] relay_gw: entered allmulticast mode [ 456.634585][ T3745] relay_src: entered allmulticast mode # smcroutectl: Cannot find IPC socket /usr/local/var/run/smcroute.sock # smcroutectl: Daemon may be running with another -i NAME [ 456.878365][ T70] br0: port 1(gw_l) entered disabled state [ 456.899160][ T70] gw_l (unregistering): left allmulticast mode [ 456.899567][ T70] gw_l (unregistering): left promiscuous mode [ 456.899901][ T70] br0: port 1(gw_l) entered disabled state [ 456.973240][ T70] amtg: left allmulticast mode [ 456.973546][ T70] amtg: left promiscuous mode [ 456.973940][ T70] br0: port 2(amtg) entered disabled state [ 456.989893][ T70] ================================================================== [ 456.990364][ T70] BUG: KASAN: slab-use-after-free in kobject_put+0xc7/0xe0 [ 456.990802][ T70] Read of size 1 at addr ffff888005f1347c by task kworker/u8:1/70 [ 456.991212][ T70] [ 456.991342][ T70] CPU: 3 PID: 70 Comm: kworker/u8:1 Not tainted 6.8.0-rc2-virtme #1 [ 456.991764][ T70] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.3-0-ga6ed6b701f0a-prebuilt.qemu.org 04/01/2014 [ 456.992405][ T70] Workqueue: netns cleanup_net [ 456.992665][ T70] Call Trace: [ 456.992849][ T70] [ 456.993018][ T70] dump_stack_lvl+0x64/0xb0 [ 456.993266][ T70] print_address_description.constprop.0+0x2c/0x3b0 [ 456.993623][ T70] ? kobject_put+0xc7/0xe0 [ 456.993883][ T70] print_report+0xb5/0x270 [ 456.994123][ T70] ? kasan_addr_to_slab+0x4e/0x90 [ 456.994396][ T70] kasan_report+0xbe/0xf0 [ 456.994662][ T70] ? kobject_put+0xc7/0xe0 [ 456.994931][ T70] kobject_put+0xc7/0xe0 [ 456.995169][ T70] br_sysfs_delbr+0x3f/0x70 [ 456.995431][ T70] br_dev_delete+0x10d/0x190 [ 456.995708][ T70] ? net_generic+0xbb/0x1f0 [bareudp] [ 456.996029][ T70] br_net_exit_batch_rtnl+0xd6/0x190 [ 456.996319][ T70] cleanup_net+0x499/0xb50 [ 456.996568][ T70] ? __pfx_lock_acquire.part.0+0x10/0x10 [ 456.996900][ T70] ? __pfx_cleanup_net+0x10/0x10 [ 456.997184][ T70] ? lock_acquire+0x1c1/0x220 [ 456.997441][ T70] ? process_one_work+0x714/0x1310 [ 456.997745][ T70] process_one_work+0x78f/0x1310 [ 456.998041][ T70] ? hlock_class+0x4e/0x130 [ 456.998308][ T70] ? __pfx_process_one_work+0x10/0x10 [ 456.998607][ T70] ? assign_work+0x16c/0x240 [ 456.998880][ T70] worker_thread+0x73d/0x1010 [ 456.999149][ T70] ? lockdep_hardirqs_on_prepare.part.0+0x1b1/0x370 [ 456.999528][ T70] ? __pfx_worker_thread+0x10/0x10 [ 456.999814][ T70] ? __pfx_worker_thread+0x10/0x10 [ 457.000126][ T70] kthread+0x292/0x360 [ 457.000355][ T70] ? __pfx_kthread+0x10/0x10 [ 457.000612][ T70] ret_from_fork+0x34/0x70 [ 457.000869][ T70] ? __pfx_kthread+0x10/0x10 [ 457.001126][ T70] ret_from_fork_asm+0x1b/0x30 [ 457.001416][ T70] [ 457.001601][ T70] [ 457.001735][ T70] Allocated by task 3724: [ 457.001971][ T70] kasan_save_stack+0x24/0x50 [ 457.002236][ T70] kasan_save_track+0x14/0x30 [ 457.002523][ T70] __kasan_kmalloc+0x7f/0x90 [ 457.002800][ T70] kobject_create_and_add+0x44/0xc0 [ 457.003081][ T70] br_sysfs_addbr+0x57/0x160 [ 457.003340][ T70] br_device_event+0x1ff/0x740 [ 457.003636][ T70] notifier_call_chain+0x9d/0x290 [ 457.003931][ T70] register_netdevice+0x116d/0x17a0 [ 457.004216][ T70] br_dev_newlink+0x2b/0x100 [ 457.004476][ T70] rtnl_newlink_create+0x344/0x850 [ 457.004776][ T70] __rtnl_newlink+0xad2/0xd60 [ 457.005060][ T70] rtnl_newlink+0x63/0xa0 [ 457.005299][ T70] rtnetlink_rcv_msg+0x2fe/0xb80 [ 457.005563][ T70] netlink_rcv_skb+0x133/0x360 [ 457.005817][ T70] netlink_unicast+0x44c/0x710 [ 457.006077][ T70] netlink_sendmsg+0x726/0xbe0 [ 457.006333][ T70] ____sys_sendmsg+0x7b5/0xa10 [ 457.006592][ T70] ___sys_sendmsg+0xee/0x170 [ 457.006840][ T70] __sys_sendmsg+0xcd/0x170 [ 457.007085][ T70] do_syscall_64+0xcc/0x1e0 [ 457.007333][ T70] entry_SYSCALL_64_after_hwframe+0x6f/0x77 [ 457.007671][ T70] [ 457.007796][ T70] Freed by task 70: [ 457.008032][ T70] kasan_save_stack+0x24/0x50 [ 457.008300][ T70] kasan_save_track+0x14/0x30 [ 457.008558][ T70] kasan_save_free_info+0x3f/0x60 [ 457.008848][ T70] __kasan_slab_free+0xfc/0x1c0 [ 457.009133][ T70] kfree+0xf2/0x2d0 [ 457.009360][ T70] kobject_cleanup+0xe2/0x280 [ 457.009620][ T70] br_sysfs_delbr+0x3f/0x70 [ 457.009884][ T70] br_dev_delete+0x10d/0x190 [ 457.010169][ T70] default_device_exit_batch_rtnl+0x112/0x210 [ 457.010510][ T70] cleanup_net+0x499/0xb50 [ 457.010759][ T70] process_one_work+0x78f/0x1310 [ 457.011049][ T70] worker_thread+0x73d/0x1010 [ 457.011335][ T70] kthread+0x292/0x360 [ 457.011571][ T70] ret_from_fork+0x34/0x70 [ 457.011814][ T70] ret_from_fork_asm+0x1b/0x30 [ 457.012073][ T70] [ 457.012233][ T70] The buggy address belongs to the object at ffff888005f13440 [ 457.012233][ T70] which belongs to the cache kmalloc-64 of size 64 [ 457.013000][ T70] The buggy address is located 60 bytes inside of [ 457.013000][ T70] freed 64-byte region [ffff888005f13440, ffff888005f13480) [ 457.013764][ T70] [ 457.013891][ T70] The buggy address belongs to the physical page: [ 457.014279][ T70] page:ffffea000017c480 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888005f13940 pfn:0x5f12 [ 457.014921][ T70] head:ffffea000017c480 order:1 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 457.015443][ T70] flags: 0x80000000000a40(workingset|slab|head|node=0|zone=1) [ 457.015844][ T70] page_type: 0xffffffff() [ 457.016080][ T70] raw: 0080000000000a40 ffff888001042900 ffffea0000069010 ffffea00000c7f10 [ 457.016566][ T70] raw: ffff888005f13940 0000000000190011 00000001ffffffff 0000000000000000 [ 457.017048][ T70] page dumped because: kasan: bad access detected [ 457.017409][ T70] [ 457.017535][ T70] Memory state around the buggy address: [ 457.017855][ T70] ffff888005f13300: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 457.018340][ T70] ffff888005f13380: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 457.018774][ T70] >ffff888005f13400: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb [ 457.019241][ T70] ^ [ 457.019659][ T70] ffff888005f13480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 457.020089][ T70] ffff888005f13500: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 457.020567][ T70] ================================================================== [ 457.021029][ T70] Disabling lock debugging due to kernel taint [ 457.021382][ T70] ------------[ cut here ]------------ [ 457.021704][ T70] refcount_t: underflow; use-after-free. [ 457.022082][ T70] WARNING: CPU: 3 PID: 70 at lib/refcount.c:28 refcount_warn_saturate+0x173/0x1b0 [ 457.022586][ T70] Modules linked in: xt_HL amt cls_matchall ip6_gre gre act_mirred act_tunnel_key cls_flower bareudp ip6_udp_tunnel udp_tunnel mpls_iptunnel mpls_router cls_bpf sch_ingress xt_conntrack nf_conntrack nf_defrag_ipv4 nft_compat nf_tables libcrc32c nf_defrag_ipv6 [ 457.023914][ T70] CPU: 3 PID: 70 Comm: kworker/u8:1 Tainted: G B 6.8.0-rc2-virtme #1 [ 457.024418][ T70] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.3-0-ga6ed6b701f0a-prebuilt.qemu.org 04/01/2014 [ 457.025108][ T70] Workqueue: netns cleanup_net [ 457.025395][ T70] RIP: 0010:refcount_warn_saturate+0x173/0x1b0 [ 457.025765][ T70] Code: f9 82 03 80 fb 01 0f 87 ee 02 b1 01 83 e3 01 0f 85 4d ff ff ff c6 05 9a f9 82 03 01 90 48 c7 c7 20 7a 62 a0 e8 3e 05 2a ff 90 <0f> 0b 90 90 e9 2f ff ff ff 48 89 df e8 8c 68 a6 ff e9 b6 fe ff ff [ 457.026899][ T70] RSP: 0018:ffffc9000050fb98 EFLAGS: 00010282 [ 457.027393][ T70] RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffffff9d91056f [ 457.027829][ T70] RDX: 0000000000000000 RSI: 0000000000000008 RDI: 0000000000000001 [ 457.028280][ T70] RBP: 0000000000000003 R08: 0000000000000000 R09: fffff520000a1f18 [ 457.028745][ T70] R10: ffffc9000050f8c7 R11: 205d303754202020 R12: ffff88800926a000 [ 457.029196][ T70] R13: ffff88800926adf8 R14: ffffc9000050fc98 R15: ffff88800926abc0 [ 457.029658][ T70] FS: 0000000000000000(0000) GS:ffff888035e00000(0000) knlGS:0000000000000000 [ 457.030170][ T70] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 457.030547][ T70] CR2: 00005557300460c8 CR3: 000000002df34002 CR4: 00000000001706f0 [ 457.031031][ T70] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 457.031451][ T70] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [ 457.031928][ T70] Call Trace: [ 457.032145][ T70] [ 457.032313][ T70] ? __warn+0xcd/0x2d0 [ 457.032552][ T70] ? refcount_warn_saturate+0x173/0x1b0 [ 457.032868][ T70] ? report_bug+0x291/0x2e0 [ 457.033135][ T70] ? vprintk_emit+0xff/0x1d0 [ 457.033402][ T70] ? handle_bug+0x3d/0x80 [ 457.033646][ T70] ? exc_invalid_op+0x18/0x50 [ 457.033943][ T70] ? asm_exc_invalid_op+0x1a/0x20 [ 457.034224][ T70] ? desc_read+0x2af/0x440 [ 457.034465][ T70] ? refcount_warn_saturate+0x173/0x1b0 [ 457.034793][ T70] ? refcount_warn_saturate+0x172/0x1b0 [ 457.035115][ T70] br_sysfs_delbr+0x3f/0x70 [ 457.035387][ T70] br_dev_delete+0x10d/0x190 [ 457.035657][ T70] ? net_generic+0xbb/0x1f0 [bareudp] [ 457.035989][ T70] br_net_exit_batch_rtnl+0xd6/0x190 [ 457.036312][ T70] cleanup_net+0x499/0xb50 [ 457.036566][ T70] ? __pfx_lock_acquire.part.0+0x10/0x10 [ 457.036918][ T70] ? __pfx_cleanup_net+0x10/0x10 [ 457.037187][ T70] ? lock_acquire+0x1c1/0x220 [ 457.037438][ T70] ? process_one_work+0x714/0x1310 [ 457.037711][ T70] process_one_work+0x78f/0x1310 [ 457.037988][ T70] ? hlock_class+0x4e/0x130 [ 457.038231][ T70] ? __pfx_process_one_work+0x10/0x10 [ 457.038547][ T70] ? assign_work+0x16c/0x240 [ 457.038798][ T70] worker_thread+0x73d/0x1010 [ 457.039061][ T70] ? lockdep_hardirqs_on_prepare.part.0+0x1b1/0x370 [ 457.039437][ T70] ? __pfx_worker_thread+0x10/0x10 [ 457.039712][ T70] ? __pfx_worker_thread+0x10/0x10 [ 457.039997][ T70] kthread+0x292/0x360 [ 457.040216][ T70] ? __pfx_kthread+0x10/0x10 [ 457.040461][ T70] ret_from_fork+0x34/0x70 [ 457.040702][ T70] ? __pfx_kthread+0x10/0x10 [ 457.040950][ T70] ret_from_fork_asm+0x1b/0x30 [ 457.041212][ T70] [ 457.041374][ T70] irq event stamp: 3835993 [ 457.041613][ T70] hardirqs last enabled at (3835993): [] irqentry_exit+0x3b/0x90 [ 457.042118][ T70] hardirqs last disabled at (3835992): [] __do_softirq+0x670/0x7ff [ 457.042622][ T70] softirqs last enabled at (3835980): [] br_dev_delete+0xd8/0x190 [ 457.043135][ T70] softirqs last disabled at (3835978): [] br_fdb_delete_by_port+0x36/0x260 [ 457.043670][ T70] ---[ end trace 0000000000000000 ]--- [ 457.043977][ T70] ------------[ cut here ]------------ [ 457.044282][ T70] sysfs group 'bridge' not found for kobject 'br0' [ 457.044648][ T70] WARNING: CPU: 3 PID: 70 at fs/sysfs/group.c:282 sysfs_remove_group+0x101/0x160 [ 457.045141][ T70] Modules linked in: xt_HL amt cls_matchall ip6_gre gre act_mirred act_tunnel_key cls_flower bareudp ip6_udp_tunnel udp_tunnel mpls_iptunnel mpls_router cls_bpf sch_ingress xt_conntrack nf_conntrack nf_defrag_ipv4 nft_compat nf_tables libcrc32c nf_defrag_ipv6 [ 457.046709][ T70] CPU: 3 PID: 70 Comm: kworker/u8:1 Tainted: G B W 6.8.0-rc2-virtme #1 [ 457.047214][ T70] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.3-0-ga6ed6b701f0a-prebuilt.qemu.org 04/01/2014 [ 457.047858][ T70] Workqueue: netns cleanup_net [ 457.048121][ T70] RIP: 0010:sysfs_remove_group+0x101/0x160 [ 457.048458][ T70] Code: 89 d9 49 8b 14 24 48 b8 00 00 00 00 00 fc ff df 48 c1 e9 03 80 3c 01 00 75 45 48 8b 33 48 c7 c7 a0 a7 5c a0 e8 60 65 5e ff 90 <0f> 0b 90 90 48 83 c4 08 5b 5d 41 5c c3 cc cc cc cc e8 e9 c7 da ff [ 457.049589][ T70] RSP: 0018:ffffc9000050fba0 EFLAGS: 00010282 [ 457.050049][ T70] RAX: 0000000000000000 RBX: ffffffffa09be220 RCX: ffffffff9d91056f [ 457.050504][ T70] RDX: 0000000000000000 RSI: 0000000000000008 RDI: 0000000000000001 [ 457.050932][ T70] RBP: 0000000000000000 R08: 0000000000000000 R09: fffff520000a1f19 [ 457.051356][ T70] R10: ffffc9000050f8cf R11: 205d303754202020 R12: ffff88800926a628 [ 457.051781][ T70] R13: ffff88800926adf8 R14: ffffc9000050fc98 R15: ffff88800926abc0 [ 457.052237][ T70] FS: 0000000000000000(0000) GS:ffff888035e00000(0000) knlGS:0000000000000000 [ 457.052743][ T70] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 457.053098][ T70] CR2: 00005557300460c8 CR3: 000000002df34002 CR4: 00000000001706f0 [ 457.053517][ T70] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 457.053943][ T70] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [ 457.054366][ T70] Call Trace: [ 457.054548][ T70] [ 457.054715][ T70] ? __warn+0xcd/0x2d0 [ 457.054969][ T70] ? console_trylock+0x61/0xf0 [ 457.055253][ T70] ? sysfs_remove_group+0x101/0x160 [ 457.055546][ T70] ? report_bug+0x291/0x2e0 [ 457.055808][ T70] ? handle_bug+0x3d/0x80 [ 457.056067][ T70] ? exc_invalid_op+0x18/0x50 [ 457.056347][ T70] ? asm_exc_invalid_op+0x1a/0x20 [ 457.056648][ T70] ? desc_read+0x2af/0x440 [ 457.056921][ T70] ? sysfs_remove_group+0x101/0x160 [ 457.057218][ T70] br_dev_delete+0x10d/0x190 [ 457.057486][ T70] ? net_generic+0xbb/0x1f0 [bareudp] [ 457.057797][ T70] br_net_exit_batch_rtnl+0xd6/0x190 [ 457.058111][ T70] cleanup_net+0x499/0xb50 [ 457.058353][ T70] ? __pfx_lock_acquire.part.0+0x10/0x10 [ 457.058654][ T70] ? __pfx_cleanup_net+0x10/0x10 [ 457.058922][ T70] ? lock_acquire+0x1c1/0x220 [ 457.059175][ T70] ? process_one_work+0x714/0x1310 [ 457.059452][ T70] process_one_work+0x78f/0x1310 [ 457.059717][ T70] ? hlock_class+0x4e/0x130 [ 457.059979][ T70] ? __pfx_process_one_work+0x10/0x10 [ 457.060268][ T70] ? assign_work+0x16c/0x240 [ 457.060515][ T70] worker_thread+0x73d/0x1010 [ 457.060770][ T70] ? lockdep_hardirqs_on_prepare.part.0+0x1b1/0x370 [ 457.061177][ T70] ? __pfx_worker_thread+0x10/0x10 [ 457.061475][ T70] ? __pfx_worker_thread+0x10/0x10 [ 457.061760][ T70] kthread+0x292/0x360 [ 457.061999][ T70] ? __pfx_kthread+0x10/0x10 [ 457.062256][ T70] ret_from_fork+0x34/0x70 [ 457.062494][ T70] ? __pfx_kthread+0x10/0x10 [ 457.062759][ T70] ret_from_fork_asm+0x1b/0x30 [ 457.063059][ T70] [ 457.063229][ T70] irq event stamp: 3835993 [ 457.063479][ T70] hardirqs last enabled at (3835993): [] irqentry_exit+0x3b/0x90 [ 457.064016][ T70] hardirqs last disabled at (3835992): [] __do_softirq+0x670/0x7ff [ 457.064543][ T70] softirqs last enabled at (3835980): [] br_dev_delete+0xd8/0x190 [ 457.065096][ T70] softirqs last disabled at (3835978): [] br_fdb_delete_by_port+0x36/0x260 [ 457.065652][ T70] ---[ end trace 0000000000000000 ]--- [ 457.087697][ T70] relay_gw (unregistering): left allmulticast mode [ 457.101897][ T70] amtr (unregistering): left allmulticast mode ok 1 selftests: net: amt.sh # SKIP make[1]: Leaving directory '/home/virtme/testing-3/tools/testing/selftests/net' make: Leaving directory '/home/virtme/testing-3/tools/testing/selftests' xx__-> [ 457.176820][ T70] relay_src (unregistering): left allmulticast mode xx__-> xx__-> echo $? 0 xx__->