* [PATCH net] selftests: net: bridge_vlan_mcast: wait for h1 before querier check
@ 2026-04-05 21:29 Daniel Golle
2026-04-07 9:03 ` Sverdlin, Alexander
2026-04-08 3:30 ` patchwork-bot+netdevbpf
0 siblings, 2 replies; 3+ messages in thread
From: Daniel Golle @ 2026-04-05 21:29 UTC (permalink / raw)
To: David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
Simon Horman, Shuah Khan, Daniel Golle, Nikolay Aleksandrov,
netdev, linux-kselftest, linux-kernel
Cc: John Crispin, Alexander Sverdlin
The querier-interval test adds h1 (currently a slave of the VRF created
by simple_if_init) to a temporary bridge br1 acting as an outside IGMP
querier. The kernel VRF driver (drivers/net/vrf.c) calls cycle_netdev()
on every slave add and remove, toggling the interface admin-down then up.
Phylink takes the PHY down during the admin-down half of that cycle.
Since h1 and swp1 are cable-connected, swp1 also loses its link may need
several seconds to re-negotiate.
Use setup_wait_dev $h1 0 which waits for h1 to return to UP state, so the
test can rely on the link being back up at this point.
Fixes: 4d8610ee8bd77 ("selftests: net: bridge: add vlan mcast_querier_interval tests")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
---
tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh b/tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh
index 72dfbeaf56b92..e8031f68200ad 100755
--- a/tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh
+++ b/tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh
@@ -414,6 +414,7 @@ vlmc_querier_intvl_test()
bridge vlan add vid 10 dev br1 self pvid untagged
ip link set dev $h1 master br1
ip link set dev br1 up
+ setup_wait_dev $h1 0
bridge vlan add vid 10 dev $h1 master
bridge vlan global set vid 10 dev br1 mcast_snooping 1 mcast_querier 1
sleep 2
--
2.53.0
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH net] selftests: net: bridge_vlan_mcast: wait for h1 before querier check
2026-04-05 21:29 [PATCH net] selftests: net: bridge_vlan_mcast: wait for h1 before querier check Daniel Golle
@ 2026-04-07 9:03 ` Sverdlin, Alexander
2026-04-08 3:30 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 3+ messages in thread
From: Sverdlin, Alexander @ 2026-04-07 9:03 UTC (permalink / raw)
To: daniel@makrotopia.org, netdev@vger.kernel.org,
linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org
Hi Daniel,
On Sun, 2026-04-05 at 22:29 +0100, Daniel Golle wrote:
> The querier-interval test adds h1 (currently a slave of the VRF created
> by simple_if_init) to a temporary bridge br1 acting as an outside IGMP
> querier. The kernel VRF driver (drivers/net/vrf.c) calls cycle_netdev()
> on every slave add and remove, toggling the interface admin-down then up.
> Phylink takes the PHY down during the admin-down half of that cycle.
> Since h1 and swp1 are cable-connected, swp1 also loses its link may need
> several seconds to re-negotiate.
>
> Use setup_wait_dev $h1 0 which waits for h1 to return to UP state, so the
> test can rely on the link being back up at this point.
>
> Fixes: 4d8610ee8bd77 ("selftests: net: bridge: add vlan mcast_querier_interval tests")
> Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Reviewed-by: Alexander Sverdlin <alexander.sverdlin@siemens.com>
> ---
> tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh b/tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh
> index 72dfbeaf56b92..e8031f68200ad 100755
> --- a/tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh
> +++ b/tools/testing/selftests/net/forwarding/bridge_vlan_mcast.sh
> @@ -414,6 +414,7 @@ vlmc_querier_intvl_test()
> bridge vlan add vid 10 dev br1 self pvid untagged
> ip link set dev $h1 master br1
> ip link set dev br1 up
> + setup_wait_dev $h1 0
> bridge vlan add vid 10 dev $h1 master
> bridge vlan global set vid 10 dev br1 mcast_snooping 1 mcast_querier 1
> sleep 2
--
Alexander Sverdlin
Siemens AG
www.siemens.com
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH net] selftests: net: bridge_vlan_mcast: wait for h1 before querier check
2026-04-05 21:29 [PATCH net] selftests: net: bridge_vlan_mcast: wait for h1 before querier check Daniel Golle
2026-04-07 9:03 ` Sverdlin, Alexander
@ 2026-04-08 3:30 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2026-04-08 3:30 UTC (permalink / raw)
To: Daniel Golle
Cc: davem, edumazet, kuba, pabeni, horms, shuah, razor, netdev,
linux-kselftest, linux-kernel, john, alexander.sverdlin
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Sun, 5 Apr 2026 22:29:19 +0100 you wrote:
> The querier-interval test adds h1 (currently a slave of the VRF created
> by simple_if_init) to a temporary bridge br1 acting as an outside IGMP
> querier. The kernel VRF driver (drivers/net/vrf.c) calls cycle_netdev()
> on every slave add and remove, toggling the interface admin-down then up.
> Phylink takes the PHY down during the admin-down half of that cycle.
> Since h1 and swp1 are cable-connected, swp1 also loses its link may need
> several seconds to re-negotiate.
>
> [...]
Here is the summary with links:
- [net] selftests: net: bridge_vlan_mcast: wait for h1 before querier check
https://git.kernel.org/netdev/net/c/efaa71faf212
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-04-08 3:30 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-05 21:29 [PATCH net] selftests: net: bridge_vlan_mcast: wait for h1 before querier check Daniel Golle
2026-04-07 9:03 ` Sverdlin, Alexander
2026-04-08 3:30 ` patchwork-bot+netdevbpf
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox