All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net v1] nfp: fix RSS hash key size when RSS is not supported
@ 2025-09-29  5:42 Kohei Enju
  2025-09-30  1:50 ` patchwork-bot+netdevbpf
  0 siblings, 1 reply; 2+ messages in thread
From: Kohei Enju @ 2025-09-29  5:42 UTC (permalink / raw)
  To: oss-drivers, netdev
  Cc: Jakub Kicinski, Simon Horman, Andrew Lunn, David S. Miller,
	Eric Dumazet, Paolo Abeni, Kohei Enju, Louis Peens, kohei.enju

The nfp_net_get_rxfh_key_size() function returns -EOPNOTSUPP when
devices don't support RSS, and callers treat the negative value as a
large positive value since the return type is u32.

Return 0 when devices don't support RSS, aligning with the ethtool
interface .get_rxfh_key_size() that requires returning 0 in such cases.

Fixes: 9ff304bfaf58 ("nfp: add support for reporting CRC32 hash function")
Signed-off-by: Kohei Enju <enjuk@amazon.com>
---
 drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c b/drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c
index a36215195923..16c828dd5c1a 100644
--- a/drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c
+++ b/drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c
@@ -1788,7 +1788,7 @@ static u32 nfp_net_get_rxfh_key_size(struct net_device *netdev)
 	struct nfp_net *nn = netdev_priv(netdev);
 
 	if (!(nn->cap & NFP_NET_CFG_CTRL_RSS_ANY))
-		return -EOPNOTSUPP;
+		return 0;
 
 	return nfp_net_rss_key_sz(nn);
 }
-- 
2.48.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH net v1] nfp: fix RSS hash key size when RSS is not supported
  2025-09-29  5:42 [PATCH net v1] nfp: fix RSS hash key size when RSS is not supported Kohei Enju
@ 2025-09-30  1:50 ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2025-09-30  1:50 UTC (permalink / raw)
  To: Kohei Enju
  Cc: oss-drivers, netdev, kuba, horms, andrew+netdev, davem, edumazet,
	pabeni, louis.peens, kohei.enju

Hello:

This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Mon, 29 Sep 2025 14:42:15 +0900 you wrote:
> The nfp_net_get_rxfh_key_size() function returns -EOPNOTSUPP when
> devices don't support RSS, and callers treat the negative value as a
> large positive value since the return type is u32.
> 
> Return 0 when devices don't support RSS, aligning with the ethtool
> interface .get_rxfh_key_size() that requires returning 0 in such cases.
> 
> [...]

Here is the summary with links:
  - [net,v1] nfp: fix RSS hash key size when RSS is not supported
    https://git.kernel.org/netdev/net/c/8425161ac120

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-09-30  1:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-29  5:42 [PATCH net v1] nfp: fix RSS hash key size when RSS is not supported Kohei Enju
2025-09-30  1:50 ` patchwork-bot+netdevbpf

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.