nfp: fix RSS hash key size when RSS is not supported
Subsystems (3)
PATCH 1/1 nfp: fix RSS hash key size when RSS is not supported
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.
--- drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c +1 -1
@@ -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); }
Signature · 1 line
2.48.1
This patch was applied to netdev/net.git (main) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <[email protected]>:
Quoted 8 lines · On Mon, 29 Sep 2025 14:42:15 +0900 you wrote:
The
nfp_net_get_rxfh_key_size()function returns-EOPNOTSUPPwhen 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!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html