All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ido Schimmel <idosch@nvidia.com>
To: "Linus Lüssing" <linus.luessing@c0d3.blue>
Cc: bridge@lists.linux.dev, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Nikolay Aleksandrov <razor@blackwall.org>,
	Andrew Lunn <andrew+netdev@lunn.ch>,
	Simon Horman <horms@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Jakub Kicinski <kuba@kernel.org>,
	Eric Dumazet <edumazet@google.com>,
	"David S . Miller" <davem@davemloft.net>,
	Kuniyuki Iwashima <kuniyu@google.com>,
	Stanislav Fomichev <sdf@fomichev.me>,
	Xiao Liang <shaw.leon@gmail.com>
Subject: Re: [PATCH net-next v2 02/14] net: bridge: mcast: track active state, adding tests
Date: Sun, 8 Feb 2026 18:00:46 +0200	[thread overview]
Message-ID: <20260208160046.GB154003@shredder> (raw)
In-Reply-To: <20260206030123.5430-3-linus.luessing@c0d3.blue>

On Fri, Feb 06, 2026 at 03:52:08AM +0100, Linus Lüssing wrote:
> Before making any significant changes to the internals of the Linux
> bridge add some tests regarding the multicast activity. This is
> also to verify that we have the semantics of the new
> *_MCAST_ACTIVE_{V4,V6} netlink attributes as expected.
> 
> Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
> ---
>  .../net/forwarding/bridge_mdb_active.sh       | 682 ++++++++++++++++++
>  1 file changed, 682 insertions(+)
>  create mode 100755 tools/testing/selftests/net/forwarding/bridge_mdb_active.sh
> 
> diff --git a/tools/testing/selftests/net/forwarding/bridge_mdb_active.sh b/tools/testing/selftests/net/forwarding/bridge_mdb_active.sh
> new file mode 100755
> index 000000000000..5b6e14d88bc2
> --- /dev/null
> +++ b/tools/testing/selftests/net/forwarding/bridge_mdb_active.sh
> @@ -0,0 +1,682 @@
> +#!/bin/bash
> +# SPDX-License-Identifier: GPL-2.0
> +
> +# +-------+      +---------+
> +# | brq0  |      | br0     |
> +# | + $h1 |      | + $swp1 |
> +# +----|--+      +----|----+
> +#      |              |
> +#      \--------------/
> +#
> +#
> +# This script checks if we have the expected mcast_active_v{4,6} state
> +# on br0 in a variety of scenarios. This state determines if ultimately
> +# multicast snooping is applied to multicast data packets
> +# (multicast snooping active) or if they are (by default) flooded instead
> +# (multicast snooping inactive).
> +#
> +# Notably, multicast snooping can be enabled but still be inactive if not all
> +# requirements to safely apply multicast snooping to multicast data packets
> +# are met.
> +#
> +# Depending on the test case an IGMP/MLD querier might be on brq0, on br0
> +# or neither.
> +
> +
> +ALL_TESTS="
> +	test_inactive
> +	test_active_other_querier
> +	test_active_own_querier
> +	test_inactive_brdown
> +	test_inactive_nov6
> +	test_inactive_snooping_off
> +	test_inactive_querier_off
> +	test_inactive_other_querier_norespdelay
> +	test_inactive_own_querier_norespdelay
> +	test_inactive
> +	test_vlan_inactive
> +	test_vlan_active_other_querier
> +	test_vlan_active_own_querier
> +	test_vlan_inactive_brdown
> +	test_vlan_inactive_nov6
> +	test_vlan_inactive_snooping_off
> +	test_vlan_inactive_vlans_snooping_off
> +	test_vlan_inactive_vlan_snooping_off
> +	test_vlan_inactive_other_querier_norespdelay
> +	test_vlan_inactive_own_querier_norespdelay
> +"
> +
> +NUM_NETIFS=1

Shouldn't this be "2" given below you have "swp1=${NETIFS[p2]}"?

> +MCAST_MAX_RESP_IVAL_SEC=1
> +MCAST_VLAN_ID=42
> +source lib.sh
> +
> +switch_create()
> +{
> +	ip link add dev br0 type bridge\
> +		vlan_filtering 0 \
> +		mcast_query_response_interval $((${MCAST_MAX_RESP_IVAL_SEC}*100))\
> +		mcast_snooping 0 \
> +		mcast_vlan_snooping 0
> +	ip link add dev brq0 type bridge\
> +		vlan_filtering 0 \
> +		mcast_query_response_interval $((${MCAST_MAX_RESP_IVAL_SEC}*100))\
> +		mcast_snooping 0 \
> +		mcast_vlan_snooping 0
> +
> +	echo 1 > /proc/sys/net/ipv6/conf/br0/disable_ipv6
> +	echo 1 > /proc/sys/net/ipv6/conf/brq0/disable_ipv6
> +
> +	ip link set dev $swp1 master br0
> +	ip link set dev $h1 master brq0
> +
> +	ip link set dev $h1 up
> +	ip link set dev $swp1 up
> +}
> +
> +switch_destroy()
> +{
> +	ip link set dev $swp1 down
> +	ip link set dev $h1 down
> +
> +	ip link del dev brq0
> +	ip link del dev br0
> +}
> +
> +setup_prepare()
> +{
> +	h1=${NETIFS[p1]}
> +	swp1=${NETIFS[p2]}
> +
> +	switch_create
> +}
> +
> +cleanup()
> +{
> +	pre_cleanup
> +	switch_destroy
> +}
> +
> +mcast_active_check()
> +{
> +	local af="$1"
> +	local state="$2"
> +
> +	ip -d -j link show dev br0\
> +		| jq -e ".[] | select(.linkinfo.info_data.mcast_active_$af == $state)"\
> +		&> /dev/null
> +
> +	check_err $? "Mcast active check failed"

Please include the address family in the error message to make it
clearer what failed. Same in other places

> +}
> +
> +mcast_vlan_active_check()
> +{
> +	local af="$1"
> +	local state="$2"
> +	local vid="${MCAST_VLAN_ID}"
> +	local ret
> +
> +	bridge -j vlan global show dev br0\
> +		| jq -e ".[].vlans.[] | select(.vlan == $vid and .mcast_active_$af == 1)"\
> +		&> /dev/null
> +	ret="$?"
> +
> +	if [ $ret -eq 0 -a $state -eq 0 ] || [ $ret -ne 0 -a $state -eq 1 ]; then
> +		check_err 1 "Mcast VLAN active check failed"
> +	fi
> +}
> +
> +mcast_assert_active_v4()
> +{
> +	mcast_active_check "v4" "1"
> +}
> +
> +mcast_assert_active_v6()
> +{
> +	mcast_active_check "v6" "1"
> +}
> +
> +mcast_assert_inactive_v4()
> +{
> +	mcast_active_check "v4" "0"
> +}
> +
> +mcast_assert_inactive_v6()
> +{
> +	mcast_active_check "v6" "0"
> +}
> +
> +mcast_vlan_assert_active_v4()
> +{
> +	mcast_vlan_active_check "v4" "1"
> +}
> +
> +mcast_vlan_assert_active_v6()
> +{
> +	mcast_vlan_active_check "v6" "1"
> +}
> +
> +mcast_vlan_assert_inactive_v4()
> +{
> +	mcast_vlan_active_check "v4" "0"
> +}
> +
> +mcast_vlan_assert_inactive_v6()
> +{
> +	mcast_vlan_active_check "v6" "0"
> +}
> +
> +

Double blank line

> +test_inactive_nolog()
> +{
> +	ip link set dev br0 down
> +	ip link set dev brq0 down
> +	ip link set dev br0 type bridge mcast_snooping 0
> +	ip link set dev brq0 type bridge mcast_snooping 0
> +	ip link set dev br0 type bridge mcast_querier 0
> +	ip link set dev brq0 type bridge mcast_querier 0
> +	ip link set dev br0 type bridge mcast_vlan_snooping 0
> +	ip link set dev br0 type bridge vlan_filtering 0
> +
> +	echo 1 > /proc/sys/net/ipv6/conf/br0/disable_ipv6
> +	echo 1 > /proc/sys/net/ipv6/conf/brq0/disable_ipv6
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +}
> +
> +test_inactive()
> +{
> +	RET=0
> +
> +	test_inactive_nolog
> +	log_test "Mcast inactive test"
> +}
> +
> +wait_lladdr_dad() {
> +	local check_tentative
> +
> +	check_tentative="map(select(.scope == \"link\" and ((.tentative == true) | not))) | .[]"
> +
> +	ip -6 -j a s dev "$1"\
> +		| jq -e ".[].addr_info | ${check_tentative}" &> /dev/null
> +}
> +
> +test_active_setup_bridge()
> +{
> +	[ -n "$1" ] && echo 0 > /proc/sys/net/ipv6/conf/br0/disable_ipv6
> +	[ -n "$2" ] && echo 0 > /proc/sys/net/ipv6/conf/brq0/disable_ipv6
> +
> +	[ -n "$3" ] && ip link set dev br0 up
> +	[ -n "$4" ] && ip link set dev brq0 up
> +	[ -n "$5" ] && slowwait 3 wait_lladdr_dad br0
> +	[ -n "$6" ] && slowwait 3 wait_lladdr_dad brq0
> +}
> +
> +test_active_setup_config()
> +{
> +	[ -n "$1" ] && ip link set dev br0 type bridge mcast_snooping 1
> +	[ -n "$2" ] && ip link set dev brq0 type bridge mcast_snooping 1
> +	[ -n "$3" ] && ip link set dev br0 type bridge mcast_querier 1
> +	[ -n "$4" ] && ip link set dev brq0 type bridge mcast_querier 1
> +}
> +
> +test_active_setup_wait()
> +{
> +	sleep $((${MCAST_MAX_RESP_IVAL_SEC} * 2))
> +}
> +
> +test_active_setup_reset_own_querier()
> +{
> +	ip link set dev br0 type bridge mcast_querier 0
> +	ip link set dev br0 type bridge mcast_querier 1
> +
> +	test_active_setup_wait
> +}
> +
> +test_vlan_active_setup_config()
> +{
> +	[ -n "$1" ] && ip link set dev br0 type bridge vlan_filtering 1
> +	[ -n "$2" ] && ip link set dev brq0 type bridge vlan_filtering 1
> +	[ -n "$3" ] && ip link set dev br0 type bridge mcast_vlan_snooping 1
> +	[ -n "$4" ] && ip link set dev brq0 type bridge mcast_vlan_snooping 1
> +}
> +
> +test_vlan_active_setup_add_vlan()
> +{
> +	bridge vlan add vid ${MCAST_VLAN_ID} dev $swp1
> +	bridge vlan add vid ${MCAST_VLAN_ID} dev $h1
> +	bridge vlan global set vid ${MCAST_VLAN_ID} dev br0\
> +		mcast_query_response_interval $((${MCAST_MAX_RESP_IVAL_SEC}*100))
> +	bridge vlan global set vid ${MCAST_VLAN_ID} dev brq0\
> +		mcast_query_response_interval $((${MCAST_MAX_RESP_IVAL_SEC}*100))
> +	bridge vlan global set vid ${MCAST_VLAN_ID} dev br0 mcast_snooping 0
> +	bridge vlan global set vid ${MCAST_VLAN_ID} dev brq0 mcast_snooping 0
> +	bridge vlan global set vid ${MCAST_VLAN_ID} dev br0 mcast_querier 0
> +	bridge vlan global set vid ${MCAST_VLAN_ID} dev brq0 mcast_querier 0
> +}
> +
> +test_vlan_active_setup_config_vlan()
> +{
> +	[ -n "$1" ] && bridge vlan global set vid ${MCAST_VLAN_ID} dev br0 mcast_snooping 1
> +	[ -n "$2" ] && bridge vlan global set vid ${MCAST_VLAN_ID} dev brq0 mcast_snooping 1
> +	[ -n "$3" ] && bridge vlan global set vid ${MCAST_VLAN_ID} dev br0 mcast_querier 1
> +	[ -n "$4" ] && bridge vlan global set vid ${MCAST_VLAN_ID} dev brq0 mcast_querier 1
> +}
> +
> +test_vlan_teardown()
> +{
> +	bridge vlan del vid ${MCAST_VLAN_ID} dev $swp1
> +	bridge vlan del vid ${MCAST_VLAN_ID} dev $h1
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +}
> +
> +test_vlan_active_setup_reset_own_querier()
> +{
> +	bridge vlan global set vid ${MCAST_VLAN_ID} dev br0 mcast_querier 0
> +	bridge vlan global set vid ${MCAST_VLAN_ID} dev br0 mcast_querier 1
> +
> +	test_active_setup_wait
> +}
> +
> +test_active_other_querier_nolog()
> +{
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  "4"
> +	test_active_setup_wait
> +
> +	mcast_assert_active_v4
> +	mcast_assert_active_v6
> +}
> +
> +test_active_other_querier()
> +{
> +	RET=0
> +
> +	test_active_other_querier_nolog
> +	test_inactive_nolog
> +	log_test "Mcast active with other querier test"
> +}
> +
> +test_active_own_querier_nolog()
> +{
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_active_v4
> +	mcast_assert_active_v6
> +}
> +
> +test_active_own_querier()
> +{
> +	RET=0
> +
> +	test_active_own_querier_nolog
> +	test_inactive_nolog
> +	log_test "Mcast active with own querier test"
> +}
> +
> +test_active_final()
> +{
> +	mcast_assert_active_v4
> +	mcast_assert_active_v6
> +
> +	test_inactive_nolog
> +}
> +
> +test_inactive_brdown()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" ""  "4" ""  "6"
> +	test_active_setup_config "1" "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +
> +	test_active_setup_bridge ""  ""  "3" ""  ""  ""
> +	mcast_assert_active_v4
> +	mcast_assert_inactive_v6
> +
> +	test_active_setup_bridge ""  ""  ""  ""  "5" ""
> +	test_active_setup_reset_own_querier
> +	test_active_final
> +
> +	log_test "Mcast inactive, bridge down test"
> +}
> +
> +test_inactive_nov6()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge ""  "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_active_v4
> +	mcast_assert_inactive_v6
> +
> +	test_active_setup_bridge "1" ""  ""  ""  "5" ""
> +	test_active_setup_reset_own_querier
> +	test_active_final
> +
> +	log_test "Mcast inactive, own querier, no IPv6 address test"
> +}
> +
> +test_inactive_snooping_off()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config ""  "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +
> +	test_active_setup_config "1" ""  ""  ""
> +	test_active_setup_reset_own_querier
> +	test_active_final
> +
> +	log_test "Mcast inactive, snooping disabled test"
> +}
> +
> +test_inactive_querier_off()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +
> +	test_active_setup_config ""  ""  "3" ""
> +	test_active_setup_wait
> +	test_active_final
> +
> +	log_test "Mcast inactive, no querier test"
> +}
> +
> +test_inactive_other_querier_norespdelay()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" "3" ""
> +	#test_active_setup_wait

Why the comment? There are more instances below

> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +
> +	test_active_setup_wait
> +	test_active_final
> +
> +	log_test "Mcast inactive, other querier, no response delay test"
> +}
> +
> +test_inactive_own_querier_norespdelay()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  "4"
> +	#test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +
> +	test_active_setup_wait
> +	test_active_final
> +
> +	log_test "Mcast inactive, own querier, no response delay test"
> +}
> +
> +test_vlan_inactive()
> +{
> +	RET=0
> +
> +	test_inactive_nolog
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +
> +	ip link set dev br0 type bridge vlan_filtering 1
> +	ip link set dev br0 type bridge mcast_vlan_snooping 1
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +
> +	ip link set dev br0 type bridge mcast_vlan_snooping 0
> +	ip link set dev br0 type bridge vlan_filtering 0
> +	test_active_own_querier_nolog
> +	ip link set dev br0 type bridge vlan_filtering 1
> +	mcast_assert_active_v4
> +	mcast_assert_active_v6
> +
> +	ip link set dev br0 type bridge mcast_vlan_snooping 1
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +
> +	test_inactive_nolog
> +	log_test "Mcast VLAN inactive test"
> +}
> +
> +test_vlan_active_final()
> +{
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_active_v4
> +	mcast_vlan_assert_active_v6
> +
> +	test_vlan_teardown
> +	test_inactive_nolog
> +}
> +
> +test_vlan_active_other_querier()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" "3" "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan "1" "2" ""  "4"
> +	test_active_setup_wait
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN active, other querier test"
> +}
> +
> +test_vlan_active_own_querier()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" "3" "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan "1" "2" "3" ""
> +	test_active_setup_wait
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN active, own querier test"
> +}
> +
> +test_vlan_inactive_brdown()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" ""  "4" ""  "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" "3" "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan "1" "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +
> +	test_active_setup_bridge ""  ""  "3" ""  ""  ""
> +	mcast_vlan_assert_active_v4
> +	mcast_assert_inactive_v6
> +
> +	test_active_setup_bridge ""  ""  ""  ""  "5" ""
> +	test_vlan_active_setup_reset_own_querier
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN inactive, bridge down test"
> +}
> +
> +test_vlan_inactive_nov6()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge ""  "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" "3" "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan "1" "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_active_v4
> +	mcast_vlan_assert_inactive_v6
> +
> +	test_active_setup_bridge "1" ""  ""  ""  "5" ""
> +	test_vlan_active_setup_reset_own_querier
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN inactive, own querier, no IPv6 address test"
> +}
> +
> +test_vlan_inactive_snooping_off()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config ""  "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" "3" "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan "1" "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +
> +	test_active_setup_config "1" ""  ""  ""
> +	test_vlan_active_setup_reset_own_querier
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN inactive, snooping disabled test"
> +}
> +
> +test_vlan_inactive_vlans_snooping_off()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" ""  "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan "1" "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +
> +	test_vlan_active_setup_config ""  ""  "3" ""
> +	test_vlan_active_setup_reset_own_querier
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN inactive, snooping for VLANs disabled test"
> +}
> +
> +test_vlan_inactive_vlan_snooping_off()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" "3" "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan ""  "2" "3" ""
> +	test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +
> +	test_vlan_active_setup_config_vlan "1" ""  ""  ""
> +	test_vlan_active_setup_reset_own_querier
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN inactive, snooping for this VLAN disabled test"
> +}
> +
> +test_vlan_inactive_other_querier_norespdelay()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" "3" "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan "1" "2" ""  "4"
> +	#test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +
> +	test_active_setup_wait
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN inactive, other querier, no response delay test"
> +}
> +
> +test_vlan_inactive_own_querier_norespdelay()
> +{
> +	RET=0
> +
> +	test_active_setup_bridge "1" "2" "3" "4" "5" "6"
> +	test_active_setup_config "1" "2" ""  ""
> +	test_vlan_active_setup_config "1" "2" "3" "4"
> +	test_vlan_active_setup_add_vlan
> +	test_vlan_active_setup_config_vlan "1" "2" "3" ""
> +	#test_active_setup_wait
> +
> +	mcast_assert_inactive_v4
> +	mcast_assert_inactive_v6
> +	mcast_vlan_assert_inactive_v4
> +	mcast_vlan_assert_inactive_v6
> +
> +	test_active_setup_wait
> +	test_vlan_active_final
> +
> +	log_test "Mcast VLAN inactive, own querier, no response delay test"
> +}
> +

The test should check if the new attributes are supported by iproute2
and skip if they are not present. See bridge_activity_notify.sh, for
example.

> +trap cleanup EXIT
> +
> +setup_prepare
> +setup_wait
> +
> +tests_run
> +
> +exit $EXIT_STATUS
> -- 
> 2.51.0
> 

  parent reply	other threads:[~2026-02-08 16:00 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-06  2:52 [PATCH net-next v2 00/14] net: bridge: reduce multicast checks in fast path Linus Lüssing
2026-02-06  2:52 ` [PATCH net-next v2 01/14] net: bridge: mcast: export ip{4,6}_active state to netlink Linus Lüssing
2026-02-08 16:00   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 02/14] net: bridge: mcast: track active state, adding tests Linus Lüssing
2026-02-07  4:58   ` Jakub Kicinski
2026-02-08 16:00   ` Ido Schimmel [this message]
2026-02-10 21:06     ` Linus Lüssing
2026-02-11  9:42       ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 03/14] net: bridge: mcast: avoid sleeping on bridge-down Linus Lüssing
2026-02-08 11:41   ` Ido Schimmel
2026-02-08 16:01   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 04/14] net: bridge: mcast: track active state, IGMP/MLD querier appearance Linus Lüssing
2026-02-08 16:07   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 05/14] net: bridge: mcast: track active state, foreign IGMP/MLD querier disappearance Linus Lüssing
2026-02-07  4:56   ` [net-next,v2,05/14] " Jakub Kicinski
2026-02-11  3:05     ` Linus Lüssing
2026-02-08 16:08   ` [PATCH net-next v2 05/14] " Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 06/14] net: bridge: mcast: track active state, IPv6 address availability Linus Lüssing
2026-02-08 16:08   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 07/14] net: bridge: mcast: track active state, own MLD querier disappearance Linus Lüssing
2026-02-08 16:09   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 08/14] net: bridge: mcast: track active state, if snooping is enabled Linus Lüssing
2026-02-08 16:09   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 09/14] net: bridge: mcast: track active state, VLAN snooping Linus Lüssing
2026-02-08 16:10   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 10/14] net: bridge: mcast: track active state, bridge up/down Linus Lüssing
2026-02-08 16:10   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 11/14] net: bridge: mcast: track active state, prepare for outside lock reads Linus Lüssing
2026-02-08 16:11   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 12/14] net: bridge: mcast: use combined active state in netlink Linus Lüssing
2026-02-08 16:11   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 13/14] net: bridge: mcast: use combined active state in fast/data path Linus Lüssing
2026-02-08 16:12   ` Ido Schimmel
2026-02-06  2:52 ` [PATCH net-next v2 14/14] net: bridge: mcast: add inactive state assertions Linus Lüssing
2026-02-08 16:13   ` Ido Schimmel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260208160046.GB154003@shredder \
    --to=idosch@nvidia.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=bridge@lists.linux.dev \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=kuniyu@google.com \
    --cc=linus.luessing@c0d3.blue \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=razor@blackwall.org \
    --cc=sdf@fomichev.me \
    --cc=shaw.leon@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.