make -C tools/testing/selftests TARGETS=net TEST_PROGS=test_vxlan_mdb.sh TTEST_GEN_PROGS="" 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: test_vxlan_mdb.sh [ 1102.850222][ T5863] veth0: renamed from veth1 [ 1107.805775][ T5891] br0: port 1(vx0) entered blocking state [ 1107.806193][ T5891] br0: port 1(vx0) entered disabled state [ 1107.806574][ T5891] vx0: entered allmulticast mode [ 1107.808057][ T5891] vx0: entered promiscuous mode [ 1107.811190][ T5891] br0: port 1(vx0) entered blocking state [ 1107.811600][ T5891] br0: port 1(vx0) entered forwarding state [ 1114.339148][ T5924] br0: port 1(vx0) entered blocking state [ 1114.339627][ T5924] br0: port 1(vx0) entered disabled state [ 1114.339968][ T5924] vx0: entered allmulticast mode [ 1114.341366][ T5924] vx0: entered promiscuous mode [ 1114.348466][ T5924] br0: port 1(vx0) entered blocking state [ 1114.348787][ T5924] br0: port 1(vx0) entered forwarding state [ 1118.413864][ T5951] veth0: renamed from veth1 [ 1122.980359][ T5978] br0: port 1(vx0) entered blocking state [ 1122.980701][ T5978] br0: port 1(vx0) entered disabled state [ 1122.981028][ T5978] vx0: entered allmulticast mode [ 1122.982615][ T5978] vx0: entered promiscuous mode [ 1122.984987][ T5978] br0: port 1(vx0) entered blocking state [ 1122.985318][ T5978] br0: port 1(vx0) entered forwarding state [ 1129.335333][ T6008] br0: port 1(vx0) entered blocking state [ 1129.335688][ T6008] br0: port 1(vx0) entered disabled state [ 1129.336018][ T6008] vx0: entered allmulticast mode [ 1129.337924][ T6008] vx0: entered promiscuous mode [ 1129.340542][ T6008] br0: port 1(vx0) entered blocking state [ 1129.340855][ T6008] br0: port 1(vx0) entered forwarding state # # Control path: Basic (*, G) operations - IPv4 overlay / IPv4 underlay # -------------------------------------------------------------------- # TEST: MDB entry addition [ OK ] # TEST: MDB entry presence after addition [ OK ] # TEST: MDB entry replacement [ OK ] # TEST: MDB entry presence after replacement [ OK ] # TEST: MDB entry deletion [ OK ] # TEST: MDB entry presence after deletion [ OK ] # TEST: Non-existent MDB entry deletion [ OK ] # TEST: MDB entry default protocol [ OK ] # TEST: MDB entry protocol replacement [ OK ] # TEST: MDB entry default destination port [ OK ] # TEST: MDB entry destination port replacement [ OK ] # TEST: MDB entry default destination VNI [ OK ] # TEST: MDB entry destination VNI replacement [ OK ] # TEST: MDB entry default outgoing interface [ OK ] # TEST: MDB entry outgoing interface replacement [ OK ] # TEST: MDB entry with mismatch between device and port [ OK ] # TEST: MDB entry with temp state [ OK ] # TEST: MDB entry with VLAN [ OK ] # TEST: MDB entry MAC address [ OK ] # TEST: MDB entry without extended parameters [ OK ] # TEST: MDB entry with an invalid protocol [ OK ] # TEST: MDB entry with an invalid destination VNI [ OK ] # TEST: MDB entry with an invalid source VNI [ OK ] # TEST: MDB entry without a remote destination IP [ OK ] # TEST: Duplicate MDB entries [ OK ] [ 1144.207572][ T69] vx0: left allmulticast mode [ 1144.207908][ T69] vx0: left promiscuous mode [ 1144.208387][ T69] br0: port 1(vx0) entered disabled state [ 1144.322373][ T69] ================================================================== [ 1144.322889][ T69] BUG: KASAN: slab-out-of-bounds in vxlan_netdevice_event+0x32f/0x340 [vxlan] [ 1144.323400][ T69] Read of size 8 at addr ffff888037648bf0 by task kworker/u8:1/69 [ 1144.323826][ T69] [ 1144.323970][ T69] CPU: 1 PID: 69 Comm: kworker/u8:1 Not tainted 6.8.0-rc2-virtme #1 [ 1144.324439][ T69] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.3-0-ga6ed6b701f0a-prebuilt.qemu.org 04/01/2014 [ 1144.325093][ T69] Workqueue: netns cleanup_net [ 1144.325387][ T69] Call Trace: [ 1144.325562][ T69] [ 1144.325716][ T69] dump_stack_lvl+0x64/0xb0 [ 1144.325979][ T69] print_address_description.constprop.0+0x2c/0x3b0 [ 1144.326394][ T69] ? vxlan_netdevice_event+0x32f/0x340 [vxlan] [ 1144.326745][ T69] print_report+0xb5/0x270 [ 1144.327009][ T69] ? kasan_addr_to_slab+0x4e/0x90 [ 1144.327311][ T69] kasan_report+0xbe/0xf0 [ 1144.327536][ T69] ? vxlan_netdevice_event+0x32f/0x340 [vxlan] [ 1144.327888][ T69] vxlan_netdevice_event+0x32f/0x340 [vxlan] [ 1144.328211][ T69] ? __pfx_vxlan_netdevice_event+0x10/0x10 [vxlan] [ 1144.328571][ T69] ? nft_offload_netdev_event+0x158/0x3b0 [nf_tables] [ 1144.328989][ T69] notifier_call_chain+0x9a/0x290 [ 1144.329255][ T69] unregister_netdevice_many_notify+0x55a/0x1180 [ 1144.329585][ T69] ? mutex_is_locked+0x17/0x50 [ 1144.329855][ T69] ? __pfx_unregister_netdevice_many_notify+0x10/0x10 [ 1144.330201][ T69] ? __pfx_unregister_netdevice_queue+0x10/0x10 [ 1144.330523][ T69] default_device_exit_batch+0x228/0x2c0 [ 1144.330831][ T69] ? __pfx_default_device_exit_batch+0x10/0x10 [ 1144.331146][ T69] ? mutex_is_locked+0x17/0x50 [ 1144.331393][ T69] ? nexthop_net_exit_batch_rtnl+0x83/0x210 [ 1144.331724][ T69] cleanup_net+0x4f3/0xb50 [ 1144.331955][ T69] ? __pfx_lock_acquire.part.0+0x10/0x10 [ 1144.332244][ T69] ? __pfx_cleanup_net+0x10/0x10 [ 1144.332499][ T69] ? lock_acquire+0x1c1/0x220 [ 1144.332745][ T69] ? process_one_work+0x714/0x1310 [ 1144.333010][ T69] process_one_work+0x78c/0x1310 [ 1144.333267][ T69] ? hlock_class+0x4e/0x130 [ 1144.333565][ T69] ? __pfx_process_one_work+0x10/0x10 [ 1144.333849][ T69] ? assign_work+0x16c/0x240 [ 1144.334137][ T69] worker_thread+0x73d/0x1010 [ 1144.334380][ T69] ? lockdep_hardirqs_on_prepare.part.0+0x1b1/0x370 [ 1144.334768][ T69] ? __pfx_worker_thread+0x10/0x10 [ 1144.335057][ T69] ? __pfx_worker_thread+0x10/0x10 [ 1144.335320][ T69] kthread+0x28f/0x360 [ 1144.335565][ T69] ? __pfx_kthread+0x10/0x10 [ 1144.335860][ T69] ret_from_fork+0x31/0x70 [ 1144.336113][ T69] ? __pfx_kthread+0x10/0x10 [ 1144.336395][ T69] ret_from_fork_asm+0x1b/0x30 [ 1144.336662][ T69] [ 1144.336820][ T69] [ 1144.336943][ T69] Allocated by task 69: [ 1144.337187][ T69] kasan_save_stack+0x24/0x50 [ 1144.337485][ T69] kasan_save_track+0x14/0x30 [ 1144.337726][ T69] __kasan_kmalloc+0x7f/0x90 [ 1144.338003][ T69] __kmalloc_node_track_caller+0x1fb/0x440 [ 1144.338317][ T69] kmalloc_reserve+0xbc/0x1f0 [ 1144.338594][ T69] __alloc_skb+0xd4/0x280 [ 1144.338861][ T69] inet6_rt_notify+0xda/0x280 [ 1144.339104][ T69] fib6_del_route+0x823/0x11e0 [ 1144.339394][ T69] fib6_del+0x1f4/0x2e0 [ 1144.339647][ T69] fib6_clean_node+0x31a/0x510 [ 1144.339897][ T69] fib6_walk_continue+0x2ff/0x610 [ 1144.340187][ T69] fib6_walk+0x152/0x380 [ 1144.340452][ T69] fib6_clean_tree+0xaf/0xf0 [ 1144.340712][ T69] __fib6_clean_all+0xe0/0x230 [ 1144.340959][ T69] rt6_disable_ip+0x11c/0x140 [ 1144.341212][ T69] addrconf_ifdown.isra.0+0x104/0x1540 [ 1144.341519][ T69] addrconf_notify+0xd1/0xd40 [ 1144.341800][ T69] notifier_call_chain+0x9a/0x290 [ 1144.342070][ T69] dev_close_many+0x2d8/0x650 [ 1144.342328][ T69] unregister_netdevice_many_notify+0x3d5/0x1180 [ 1144.342662][ T69] default_device_exit_batch+0x228/0x2c0 [ 1144.342982][ T69] cleanup_net+0x4f3/0xb50 [ 1144.343254][ T69] process_one_work+0x78c/0x1310 [ 1144.343536][ T69] worker_thread+0x73d/0x1010 [ 1144.343787][ T69] kthread+0x28f/0x360 [ 1144.343997][ T69] ret_from_fork+0x31/0x70 [ 1144.344269][ T69] ret_from_fork_asm+0x1b/0x30 [ 1144.344549][ T69] [ 1144.344673][ T69] Freed by task 69: [ 1144.344899][ T69] kasan_save_stack+0x24/0x50 [ 1144.345143][ T69] kasan_save_track+0x14/0x30 [ 1144.345411][ T69] kasan_save_free_info+0x3f/0x60 [ 1144.345706][ T69] __kasan_slab_free+0xfc/0x1c0 [ 1144.345994][ T69] kfree+0xf2/0x2d0 [ 1144.346193][ T69] skb_release_data+0x56b/0x770 [ 1144.346496][ T69] consume_skb+0xad/0x110 [ 1144.346733][ T69] netlink_broadcast_filtered+0x224/0x340 [ 1144.347059][ T69] nlmsg_notify+0x6e/0x1e0 [ 1144.347293][ T69] fib6_del_route+0x823/0x11e0 [ 1144.347580][ T69] fib6_del+0x1f4/0x2e0 [ 1144.347827][ T69] fib6_clean_node+0x31a/0x510 [ 1144.348072][ T69] fib6_walk_continue+0x2ff/0x610 [ 1144.348344][ T69] fib6_walk+0x152/0x380 [ 1144.348561][ T69] fib6_clean_tree+0xaf/0xf0 [ 1144.348830][ T69] __fib6_clean_all+0xe0/0x230 [ 1144.349119][ T69] rt6_disable_ip+0x11c/0x140 [ 1144.349361][ T69] addrconf_ifdown.isra.0+0x104/0x1540 [ 1144.349682][ T69] addrconf_notify+0xd1/0xd40 [ 1144.349936][ T69] notifier_call_chain+0x9a/0x290 [ 1144.350196][ T69] dev_close_many+0x2d8/0x650 [ 1144.350438][ T69] unregister_netdevice_many_notify+0x3d5/0x1180 [ 1144.350763][ T69] default_device_exit_batch+0x228/0x2c0 [ 1144.351052][ T69] cleanup_net+0x4f3/0xb50 [ 1144.351279][ T69] process_one_work+0x78c/0x1310 [ 1144.351531][ T69] worker_thread+0x73d/0x1010 [ 1144.351772][ T69] kthread+0x28f/0x360 [ 1144.351980][ T69] ret_from_fork+0x31/0x70 [ 1144.352208][ T69] ret_from_fork_asm+0x1b/0x30 [ 1144.352454][ T69] [ 1144.352575][ T69] The buggy address belongs to the object at ffff888037648400 [ 1144.352575][ T69] which belongs to the cache kmalloc-1k of size 1024 [ 1144.353278][ T69] The buggy address is located 1008 bytes to the right of [ 1144.353278][ T69] allocated 1024-byte region [ffff888037648400, ffff888037648800) [ 1144.354040][ T69] [ 1144.354163][ T69] The buggy address belongs to the physical page: [ 1144.354612][ T69] page:ffffea0000dd9200 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff88803764c000 pfn:0x37648 [ 1144.355420][ T69] head:ffffea0000dd9200 order:3 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 1144.356156][ T69] flags: 0x80000000000a40(workingset|slab|head|node=0|zone=1) [ 1144.356758][ T69] page_type: 0xffffffff() [ 1144.357110][ T69] raw: 0080000000000a40 ffff888001043380 ffff8880010416d0 ffff8880010416d0 [ 1144.357820][ T69] raw: ffff88803764c000 00000000000a0005 00000001ffffffff 0000000000000000 [ 1144.358580][ T69] page dumped because: kasan: bad access detected [ 1144.359104][ T69] [ 1144.359303][ T69] Memory state around the buggy address: [ 1144.359803][ T69] ffff888037648a80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 1144.360455][ T69] ffff888037648b00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 1144.361095][ T69] >ffff888037648b80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 1144.361746][ T69] ^ [ 1144.362406][ T69] ffff888037648c00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 1144.363017][ T69] ffff888037648c80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 1144.363621][ T69] ================================================================== [ 1144.364602][ T69] Disabling lock debugging due to kernel taint [ 1144.365122][ T69] general protection fault, probably for non-canonical address 0xeb4b474b4b4b4b4b: 0000 [#1] PREEMPT SMP KASAN NOPTI [ 1144.366123][ T69] KASAN: maybe wild-memory-access in range [0x5a5a5a5a5a5a5a58-0x5a5a5a5a5a5a5a5f] [ 1144.366867][ T69] CPU: 1 PID: 69 Comm: kworker/u8:1 Tainted: G B 6.8.0-rc2-virtme #1 [ 1144.367632][ T69] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.3-0-ga6ed6b701f0a-prebuilt.qemu.org 04/01/2014 [ 1144.368412][ T69] Workqueue: netns cleanup_net [ 1144.368663][ T69] RIP: 0010:vxlan_netdevice_event+0x19e/0x340 [vxlan] [ 1144.369038][ T69] Code: 00 00 00 48 b9 00 00 00 00 00 fc ff df 49 89 c0 48 89 44 24 08 49 c1 e8 03 4d 8d 24 08 eb 2c 48 8d 53 30 48 89 d0 48 c1 e8 03 <80> 3c 08 00 0f 85 e0 00 00 00 48 8b 43 30 49 89 dd 48 83 e8 30 49 [ 1144.370106][ T69] RSP: 0018:ffffc900004ff980 EFLAGS: 00010206 [ 1144.370463][ T69] RAX: 0b4b4b4b4b4b4b4b RBX: 5a5a5a5a5a5a5a2a RCX: dffffc0000000000 [ 1144.370891][ T69] RDX: 5a5a5a5a5a5a5a5a RSI: 0000000000000004 RDI: ffff888037648c44 [ 1144.371344][ T69] RBP: 1ffff9200009ff33 R08: 1ffff110015f981a R09: ffffc900004ff9b8 [ 1144.371743][ T69] R10: ffffffffaee34a07 R11: 205d393654202020 R12: ffffed10015f981a [ 1144.372143][ T69] R13: ffff888037648bc0 R14: ffff88800b064000 R15: ffff88800afcc000 [ 1144.372624][ T69] FS: 0000000000000000(0000) GS:ffff88802ea00000(0000) knlGS:0000000000000000 [ 1144.373147][ T69] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 1144.373526][ T69] CR2: 00007ffc67e75528 CR3: 0000000009e02004 CR4: 0000000000770ef0 [ 1144.373930][ T69] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 1144.374342][ T69] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [ 1144.374753][ T69] PKRU: 55555554 [ 1144.374935][ T69] Call Trace: [ 1144.375108][ T69] [ 1144.375264][ T69] ? die_addr+0x41/0xa0 [ 1144.375485][ T69] ? exc_general_protection+0x149/0x220 [ 1144.375776][ T69] ? asm_exc_general_protection+0x26/0x30 [ 1144.376072][ T69] ? vxlan_netdevice_event+0x19e/0x340 [vxlan] [ 1144.376409][ T69] ? __pfx_vxlan_netdevice_event+0x10/0x10 [vxlan] [ 1144.376754][ T69] ? nft_offload_netdev_event+0x158/0x3b0 [nf_tables] [ 1144.377132][ T69] notifier_call_chain+0x9a/0x290 [ 1144.377400][ T69] unregister_netdevice_many_notify+0x55a/0x1180 [ 1144.377725][ T69] ? mutex_is_locked+0x17/0x50 [ 1144.377971][ T69] ? __pfx_unregister_netdevice_many_notify+0x10/0x10 [ 1144.378315][ T69] ? __pfx_unregister_netdevice_queue+0x10/0x10 [ 1144.378704][ T69] default_device_exit_batch+0x228/0x2c0 [ 1144.379137][ T69] ? __pfx_default_device_exit_batch+0x10/0x10 [ 1144.379586][ T69] ? mutex_is_locked+0x17/0x50 [ 1144.379963][ T69] ? nexthop_net_exit_batch_rtnl+0x83/0x210 [ 1144.380422][ T69] cleanup_net+0x4f3/0xb50 [ 1144.380772][ T69] ? __pfx_lock_acquire.part.0+0x10/0x10 [ 1144.381207][ T69] ? __pfx_cleanup_net+0x10/0x10 [ 1144.381589][ T69] ? lock_acquire+0x1c1/0x220 [ 1144.381952][ T69] ? process_one_work+0x714/0x1310 [ 1144.382352][ T69] process_one_work+0x78c/0x1310 [ 1144.382737][ T69] ? hlock_class+0x4e/0x130 [ 1144.383087][ T69] ? __pfx_process_one_work+0x10/0x10 [ 1144.383504][ T69] ? assign_work+0x16c/0x240 [ 1144.383860][ T69] worker_thread+0x73d/0x1010 [ 1144.384226][ T69] ? lockdep_hardirqs_on_prepare.part.0+0x1b1/0x370 [ 1144.384729][ T69] ? __pfx_worker_thread+0x10/0x10 [ 1144.385124][ T69] ? __pfx_worker_thread+0x10/0x10 [ 1144.385519][ T69] kthread+0x28f/0x360 [ 1144.385836][ T69] ? __pfx_kthread+0x10/0x10 [ 1144.386190][ T69] ret_from_fork+0x31/0x70 [ 1144.386537][ T69] ? __pfx_kthread+0x10/0x10 [ 1144.386893][ T69] ret_from_fork_asm+0x1b/0x30 [ 1144.387269][ T69] [ 1144.387506][ T69] Modules linked in: vxlan ip6_udp_tunnel udp_tunnel sha1_generic xfrm_user xt_policy nft_compat nf_tables libcrc32c [ 1144.388510][ T69] ---[ end trace 0000000000000000 ]--- [ 1144.388934][ T69] RIP: 0010:vxlan_netdevice_event+0x19e/0x340 [vxlan] [ 1144.390730][ T69] Code: 00 00 00 48 b9 00 00 00 00 00 fc ff df 49 89 c0 48 89 44 24 08 49 c1 e8 03 4d 8d 24 08 eb 2c 48 8d 53 30 48 89 d0 48 c1 e8 03 <80> 3c 08 00 0f 85 e0 00 00 00 48 8b 43 30 49 89 dd 48 83 e8 30 49 [ 1144.391760][ T69] RSP: 0018:ffffc900004ff980 EFLAGS: 00010206 [ 1144.392078][ T69] RAX: 0b4b4b4b4b4b4b4b RBX: 5a5a5a5a5a5a5a2a RCX: dffffc0000000000 [ 1144.392506][ T69] RDX: 5a5a5a5a5a5a5a5a RSI: 0000000000000004 RDI: ffff888037648c44 [ 1144.392917][ T69] RBP: 1ffff9200009ff33 R08: 1ffff110015f981a R09: ffffc900004ff9b8 [ 1144.393403][ T69] R10: ffffffffaee34a07 R11: 205d393654202020 R12: ffffed10015f981a [ 1144.393916][ T69] R13: ffff888037648bc0 R14: ffff88800b064000 R15: ffff88800afcc000 [ 1144.394333][ T69] FS: 0000000000000000(0000) GS:ffff88802ea00000(0000) knlGS:0000000000000000 [ 1144.394787][ T69] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 1144.395123][ T69] CR2: 00007ffc67e75528 CR3: 0000000035d34002 CR4: 0000000000770ef0 [ 1144.395539][ T69] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 1144.395942][ T69] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [ 1144.396369][ T69] PKRU: 55555554 [ 1144.396558][ T69] Kernel panic - not syncing: Fatal exception [ 1144.396966][ T69] Kernel Offset: 0x28400000 from 0xffffffff81000000 (relocation range: 0xffffffff80000000-0xffffffffbfffffff) [ 1144.397561][ T69] ---[ end Kernel panic - not syncing: Fatal exception ]--- WAIT TIMEOUT stdout Ctrl-C stdout Ctrl-C stdout WAIT TIMEOUT stdout