Linux Kernel Selftest development
 help / color / mirror / Atom feed
From: Ahmed Zaki <ahmed.zaki@intel.com>
To: Edward Cree <ecree.xilinx@gmail.com>,
	Gal Pressman <gal@nvidia.com>, <edward.cree@amd.com>,
	<davem@davemloft.net>, <kuba@kernel.org>, <edumazet@google.com>,
	<pabeni@redhat.com>
Cc: <netdev@vger.kernel.org>, <habetsm.xilinx@gmail.com>,
	<linux-net-drivers@amd.com>, <horms@kernel.org>,
	<andrew+netdev@lunn.ch>, <shuah@kernel.org>,
	<linux-kselftest@vger.kernel.org>
Subject: Re: [PATCH net-next 1/5] net: ethtool: only allow set_rxnfc with rss + ring_cookie if driver opts in
Date: Mon, 25 Nov 2024 12:01:57 -0700	[thread overview]
Message-ID: <44a203f1-1712-48f9-983a-dc49e40a3139@intel.com> (raw)
In-Reply-To: <1caf318c-db83-0335-4580-2ee21ff8940f@gmail.com>



On 2024-11-25 7:42 a.m., Edward Cree wrote:
> On 25/11/2024 14:20, Ahmed Zaki wrote:
>> On 2024-11-25 7:10 a.m., Gal Pressman wrote:
>>> On 25/11/2024 15:21, Edward Cree wrote:
>>>> Also, the check below it, dealing with sym-xor, looks like it's only
>>>>    relevant to ETHTOOL_SRXFH, since info.data is garbage for other commands.
>>>>    Ahmed, is my understanding correct there?
>>>>
>>>
>>> Speaking of the below check, the sanity check depends on the order of
>>> operations, for example:
>>> 1. Enable symmetric xor
>>> 2. Request hash on src only
>>> = Error as expected, however:
>>
>> Correct. The check below is to make sure that no ntuple that does not cover symmetric fields is added if symm-xor is enabled.
> But symm-xor is about hashing, and is only relevant to traffic being
>   directed by RSS.  The user should still be allowed to, and the NIC
>   should be able to handle, setting an ntuple filter (SRXCLSRLINS)
>   that is asymmetric, to override the symmetric hashing for selected
>   traffic.

I agree, and in its first version, the sym-xor series was setting 
sym-xor per ntuple, not per netdev. So the NIC can support different RSS 
functions for different filters. Unfortunately, this was then changed to 
be per-netdev during review. At that point, these checks were added in 
nxfc path.

> symm-xor should only constrain RXFH settings.  And in fact even if
>   you wanted to block asymm ntuple filters, the current code does not
>   do that, since the info.data fields it looks at aren't populated for
>   ntuple filters (whose filter fields are defined by info.fs).
> So the xfrm check should be under `if (info.cmd == ETHTOOL_SRXFH)`.

If it is not, then it is a bug. I will try to test later this week and 
send a fix if needed.



  reply	other threads:[~2024-11-25 19:02 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-13 12:13 [PATCH net-next 0/5] net: make RSS+RXNFC semantics more explicit edward.cree
2024-11-13 12:13 ` [PATCH net-next 1/5] net: ethtool: only allow set_rxnfc with rss + ring_cookie if driver opts in edward.cree
2024-11-14  9:21   ` Martin Habets
2024-11-25  7:11   ` Gal Pressman
2024-11-25 13:21     ` Edward Cree
2024-11-25 14:10       ` Gal Pressman
2024-11-25 14:20         ` Ahmed Zaki
2024-11-25 14:26           ` Gal Pressman
2024-11-25 14:42           ` Edward Cree
2024-11-25 19:01             ` Ahmed Zaki [this message]
2024-12-02 15:19               ` Ahmed Zaki
2024-11-25 18:13         ` Edward Cree
2024-11-13 12:13 ` [PATCH net-next 2/5] net: ethtool: account for RSS+RXNFC add semantics when checking channel count edward.cree
2024-11-13 12:13 ` [PATCH net-next 3/5] selftest: include dst-ip in ethtool ntuple rules edward.cree
2024-11-14  9:54   ` Martin Habets
2024-11-13 12:13 ` [PATCH net-next 4/5] selftest: validate RSS+ntuple filters with nonzero ring_cookie edward.cree
2024-11-13 12:13 ` [PATCH net-next 5/5] selftest: extend test_rss_context_queue_reconfigure for action addition edward.cree
2024-11-15  4:40 ` [PATCH net-next 0/5] net: make RSS+RXNFC semantics more explicit patchwork-bot+netdevbpf

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=44a203f1-1712-48f9-983a-dc49e40a3139@intel.com \
    --to=ahmed.zaki@intel.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=ecree.xilinx@gmail.com \
    --cc=edumazet@google.com \
    --cc=edward.cree@amd.com \
    --cc=gal@nvidia.com \
    --cc=habetsm.xilinx@gmail.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linux-net-drivers@amd.com \
    --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