From: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
To: Eric Dumazet <edumazet@google.com>,
"David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Paolo Abeni <pabeni@redhat.com>
Cc: Ziwei Xiao <ziweixiao@google.com>,
Praveen Kaligineedi <pkaligineedi@google.com>,
Harshitha Ramamurthy <hramamurthy@google.com>,
Willem de Bruijn <willemb@google.com>,
Jeroen de Borst <jeroendb@google.com>,
Shailend Chand <shailend@google.com>,
netdev@vger.kernel.org, eric.dumazet@gmail.com,
Eric Dumazet <edumazet@google.com>
Subject: Re: [PATCH net-next 6/6] net: ethtool: add the ability to run ethtool_[gs]et_rxnfc() without RTNL
Date: Thu, 20 Jun 2024 13:45:38 -0400 [thread overview]
Message-ID: <66746ac265e37_2bed87294ba@willemb.c.googlers.com.notmuch> (raw)
In-Reply-To: <20240620114711.777046-7-edumazet@google.com>
Eric Dumazet wrote:
> For better scalability, drivers can prefer to implement their own locking schem
> (for instance one mutex per port or queue) instead of relying on RTNL.
>
> This patch adds a new boolean field in ethtool_ops : rxnfc_parallel
>
> Drivers can opt-in to this new behavior.
>
> Signed-off-by: Eric Dumazet <edumazet@google.com>
> ---
> include/linux/ethtool.h | 2 ++
> net/ethtool/ioctl.c | 43 +++++++++++++++++++++++++++--------------
> 2 files changed, 31 insertions(+), 14 deletions(-)
>
> diff --git a/include/linux/ethtool.h b/include/linux/ethtool.h
> index 6fd9107d3cc010dd2f1ecdb005c412145c461b6c..ee9b8054165361c9236186ff61f886e53cfa6b49 100644
> --- a/include/linux/ethtool.h
> +++ b/include/linux/ethtool.h
> @@ -748,6 +748,7 @@ struct ethtool_rxfh_param {
> * error code or zero.
> * @set_rxnfc: Set RX flow classification rules. Returns a negative
> * error code or zero.
> + * @rxnfc_parallel: true if @set_rxnfc, @get_rxnfc and @get_rxfh do not need RTNL.
> * @flash_device: Write a firmware image to device's flash memory.
> * Returns a negative error code or zero.
> * @reset: Reset (part of) the device, as specified by a bitmask of
> @@ -907,6 +908,7 @@ struct ethtool_ops {
> int (*get_rxnfc)(struct net_device *,
> struct ethtool_rxnfc *, u32 *rule_locs);
> int (*set_rxnfc)(struct net_device *, struct ethtool_rxnfc *);
> + bool rxnfc_parallel;
Would it make sense to make this a bit, as there already are u32 bits
at the start of the struct, with a 29-bit gap?
next prev parent reply other threads:[~2024-06-20 17:45 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-20 11:47 [PATCH net-next 0/6] net: ethtool: reduce RTNL pressure in dev_ethtool() Eric Dumazet
2024-06-20 11:47 ` [PATCH net-next 1/6] net: ethtool: grab a netdev reference " Eric Dumazet
2024-06-20 11:47 ` [PATCH net-next 2/6] net: ethtool: add dev_ethtool_cap_check() Eric Dumazet
2024-06-20 11:47 ` [PATCH net-next 3/6] net: ethtool: perform pm duties outside of rtnl lock Eric Dumazet
2024-06-21 0:22 ` Jakub Kicinski
2024-06-21 0:59 ` Andrew Lunn
2024-06-21 2:11 ` Jakub Kicinski
2024-06-21 4:16 ` Eric Dumazet
2024-06-20 11:47 ` [PATCH net-next 4/6] net: ethtool: call ethtool_get_one_feature() without RTNL Eric Dumazet
2024-06-20 11:47 ` [PATCH net-next 5/6] net: ethtool: implement lockless ETHTOOL_GFLAGS Eric Dumazet
2024-06-20 11:47 ` [PATCH net-next 6/6] net: ethtool: add the ability to run ethtool_[gs]et_rxnfc() without RTNL Eric Dumazet
2024-06-20 17:45 ` Willem de Bruijn [this message]
2024-06-20 18:29 ` Eric Dumazet
2024-06-20 17:58 ` [PATCH net-next 0/6] net: ethtool: reduce RTNL pressure in dev_ethtool() Willem de Bruijn
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=66746ac265e37_2bed87294ba@willemb.c.googlers.com.notmuch \
--to=willemdebruijn.kernel@gmail.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=eric.dumazet@gmail.com \
--cc=hramamurthy@google.com \
--cc=jeroendb@google.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=pkaligineedi@google.com \
--cc=shailend@google.com \
--cc=willemb@google.com \
--cc=ziweixiao@google.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).