From: Ido Schimmel <idosch@nvidia.com>
To: Jack Ma <jack4it@gmail.com>
Cc: David Ahern <dsahern@kernel.org>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>, Shuah Khan <shuah@kernel.org>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-kselftest@vger.kernel.org
Subject: Re: [PATCH net-next v2 3/3] selftests: net: add coverage for fdb nexthop dst port
Date: Tue, 21 Jul 2026 18:20:59 +0300 [thread overview]
Message-ID: <20260721152059.GC2667735@shredder> (raw)
In-Reply-To: <20260717-b4-vxlan-fdb-port-v2-3-f4862e8fe867@gmail.com>
On Fri, Jul 17, 2026 at 06:45:18AM +0000, Jack Ma wrote:
> Add fib_nexthops_fdb_port.sh, which exercises the NHA_FDB_PORT rules:
> accept a port on an fdb nexthop that has a gateway and echo it back on
> dump, reject it on non-fdb or gateway-less nexthops, allow a group whose
> legs differ only in UDP port, and confirm a portless fdb nexthop omits
> the attribute. The test SKIPs cleanly on kernels or iproute2 without
> NHA_FDB_PORT support.
We already have control plane test for FDB nexthops in fib_nexthops.sh,
can you add the new test cases there instead? Probably fit in
ipv4_fdb_grp_fcnal() and ipv6_fdb_grp_fcnal()
>
> Signed-off-by: Jack Ma <jack4it@gmail.com>
> ---
> tools/testing/selftests/net/Makefile | 1 +
> .../testing/selftests/net/fib_nexthops_fdb_port.sh | 78 ++++++++++++++++++++++
> 2 files changed, 79 insertions(+)
>
> diff --git a/tools/testing/selftests/net/Makefile b/tools/testing/selftests/net/Makefile
> index 708d960ae..c06eb4927 100644
> --- a/tools/testing/selftests/net/Makefile
> +++ b/tools/testing/selftests/net/Makefile
> @@ -36,6 +36,7 @@ TEST_PROGS := \
> fib_nexthop_multiprefix.sh \
> fib_nexthop_nongw.sh \
> fib_nexthops.sh \
> + fib_nexthops_fdb_port.sh \
> fib_rule_tests.sh \
> fib_tests.sh \
> fin_ack_lat.sh \
> diff --git a/tools/testing/selftests/net/fib_nexthops_fdb_port.sh b/tools/testing/selftests/net/fib_nexthops_fdb_port.sh
> new file mode 100755
> index 000000000..8b401c6d2
> --- /dev/null
> +++ b/tools/testing/selftests/net/fib_nexthops_fdb_port.sh
> @@ -0,0 +1,78 @@
> +#!/bin/bash
> +# SPDX-License-Identifier: GPL-2.0
> +#
> +# Control-plane selftest for per-nexthop VXLAN fdb destination port
> +# (NHA_FDB_PORT). Verifies the accept/reject rules and the dump roundtrip.
> +# No datapath traffic here -- see tests/integ/vxlan-fdb-port-integ.sh for the
> +# real forwarding test.
vxlan-fdb-port-integ.sh doesn't exist. We have test_vxlan_nh.sh. Can you
extend basic_tx_common() to test the new attribute? Don't change the
existing configuration (we want to test the configuration where user
space doesn't pass a port) and instead add a new:
1. FDB nexthop and a group that contains it
2. Flower filter that also matches on the destination port (not 4789)
3. FDB entry that points to the new group
Run shellcheck (preferably via ingest_mdir.py [1]) to make sure you're
not adding new warnings / errors.
[1] https://github.com/linux-netdev/nipa#running-locally
next prev parent reply other threads:[~2026-07-21 15:21 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-17 6:45 [PATCH net-next v2 0/3] net: nexthop: per-nexthop UDP dst port for fdb (VXLAN) nexthops Jack Ma
2026-07-17 6:45 ` [PATCH net-next v2 1/3] net: nexthop: add NHA_FDB_PORT for fdb nexthops Jack Ma
2026-07-21 15:17 ` Ido Schimmel
2026-07-21 22:19 ` Jack Ma
2026-07-17 6:45 ` [PATCH net-next v2 2/3] vxlan: honor per-nexthop fdb destination port Jack Ma
2026-07-21 15:18 ` Ido Schimmel
2026-07-21 22:19 ` Jack Ma
2026-07-17 6:45 ` [PATCH net-next v2 3/3] selftests: net: add coverage for fdb nexthop dst port Jack Ma
2026-07-21 15:20 ` Ido Schimmel [this message]
2026-07-21 22:19 ` Jack Ma
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=20260721152059.GC2667735@shredder \
--to=idosch@nvidia.com \
--cc=davem@davemloft.net \
--cc=dsahern@kernel.org \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=jack4it@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=shuah@kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox