[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aMJyC_YNjVWcB7pe@fedora>
Date: Thu, 11 Sep 2025 06:54:03 +0000
From: Hangbin Liu <liuhangbin@...il.com>
To: Sabrina Dubroca <sd@...asysnail.net>
Cc: netdev@...r.kernel.org, Jay Vosburgh <jv@...sburgh.net>,
Andrew Lunn <andrew+netdev@...n.ch>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Jiri Pirko <jiri@...nulli.us>, Simon Horman <horms@...nel.org>,
Ido Schimmel <idosch@...dia.com>, Shuah Khan <shuah@...nel.org>,
Stanislav Fomichev <sdf@...ichev.me>,
Stanislav Fomichev <stfomichev@...il.com>,
Kuniyuki Iwashima <kuniyu@...gle.com>,
Alexander Lobakin <aleksander.lobakin@...el.com>,
bridge@...ts.linux.dev, linux-kselftest@...r.kernel.org
Subject: Re: [PATCHv3 net-next 5/5] selftests/net: add offload checking test
for virtual interface
On Wed, Sep 10, 2025 at 04:57:54PM +0200, Sabrina Dubroca wrote:
> 2025-09-09, 08:18:52 +0000, Hangbin Liu wrote:
> > +__check_offload()
> > +{
> > + local dev=$1
> > + local opt=$2
> > + local expect=$3
> > +
> > + ip netns exec "$ns" ethtool --json -k "$dev" | \
> > + jq -r -e ".[].\"$opt\".active == ${expect}" >/dev/null
>
> Sorry Hangbin, I should have noticed this when we discussed the IPsec
> test, since the problem is similar for the other features set in
> netdev_compute_features_from_lowers:
>
> `ethtool -k` does not test the dev->*_features (mpls, vlan, etc) set
> in the new common function, it only checks dev->features and
> dev->hw_features. So this will not test the new function.
Hmm, that make the selftest more complex. A very easy way to verify whether
the feature is set is using tracepoint. But Paolo said adding new tracepoint
is not welcomed.
Since all these flags are fixed after compute from lower devices. We need to
find out a proper device and test the features are inherited.
The next question is how to test gso_partial_features, vlan_features,
hw_enc_features, mpls_features (maybe also tso_max_segs/size in future)
effectively.
The veth device only has hw_enc_features and mpls_features, while it's
hw_enc_features doesn't have NETIF_F_HW_ESP. The netdevsim device only have
hw_enc_features.
For mpls_features, seem we only able to test NETIF_F_GSO_SOFTWARE, but I'm not
sure how to check mpls gso..
For hw_enc_features NETIF_F_HW_ESP. Does sending ipsec data and see if
netdevsim has pkts count enough??
Any advices? Should we just drop the selftest?
Thanks
Hangbin
Powered by blists - more mailing lists