Netdev List
 help / color / mirror / Atom feed
From: Ido Schimmel <idosch@nvidia.com>
To: Yifei Sun <yifei.sun@inria.fr>
Cc: netdev@vger.kernel.org, David Ahern <dsahern@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@kernel.org>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Willem de Bruijn <willemb@google.com>,
	Simon Horman <horms@kernel.org>,
	Nikolay Aleksandrov <razor@blackwall.org>,
	Shuah Khan <shuah@kernel.org>,
	linux-kselftest@vger.kernel.org
Subject: Re: [PATCH net 2/2] selftests: net: test IPv4 nexthop fallback in the same trie leaf
Date: Tue, 24 Nov 2026 17:37:42 +0200	[thread overview]
Message-ID: <20261124153742.GB3946712@shredder> (raw)
In-Reply-To: <20261121182031.36626-2-yifei.sun@inria.fr>

On Sat, Nov 21, 2026 at 07:20:17PM +0100, Yifei Sun wrote:
> Check that a lookup bound to veth1 selects the nexthop object, while
> one bound to veth3 falls back to another route in the same trie leaf.
> Cover both a shorter prefix and a higher metric for the same prefix.
> 
> Signed-off-by: Yifei Sun <yifei.sun@inria.fr>
> ---
>  tools/testing/selftests/net/fib_nexthops.sh | 23 +++++++++++++++++++++++
>  1 file changed, 23 insertions(+)
> 
> diff --git a/tools/testing/selftests/net/fib_nexthops.sh b/tools/testing/selftests/net/fib_nexthops.sh
> index adbec51917eb..38bb56f28187 100755
> --- a/tools/testing/selftests/net/fib_nexthops.sh
> +++ b/tools/testing/selftests/net/fib_nexthops.sh
> @@ -22,6 +22,7 @@ ksft_skip=4
>  # all tests in this script. Can be overridden with -t option
>  IPV4_TESTS="
>  	ipv4_fcnal
> +	ipv4_oif_fallback
>  	ipv4_grp_fcnal
>  	ipv4_res_grp_fcnal
>  	ipv4_withv6_fcnal

Please add a matching test case for IPv6. Ideally both address families
should behave the same.

Also, this test is more about the lookup semantic than nexthop objects,
so I suggest moving it to fib_tests.sh.

I suggest four test cases:

ipv4_oif_fallback - Two routes with legacy nexthops. Should pass even
w/o the fix.

ipv4_oif_fallback_nh - Two routes with nexthop objects. Should fail w/o
the fix and pass with it.

Another two for IPv6 which should pass regardless of the fix.

  reply	other threads:[~2026-11-24 15:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-21 18:20 [PATCH net 1/2] ipv4: keep scanning the leaf when a nexthop object is unusable Yifei Sun
2026-11-21 18:20 ` [PATCH net 2/2] selftests: net: test IPv4 nexthop fallback in the same trie leaf Yifei Sun
2026-11-24 15:37   ` Ido Schimmel [this message]
2026-11-24 15:37 ` [PATCH net 1/2] ipv4: keep scanning the leaf when a nexthop object is unusable 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=20261124153742.GB3946712@shredder \
    --to=idosch@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=edumazet@kernel.org \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=razor@blackwall.org \
    --cc=shuah@kernel.org \
    --cc=willemb@google.com \
    --cc=yifei.sun@inria.fr \
    /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