patches for DPDK stable branches
 help / color / mirror / Atom feed
* [PATCH 2/2] net/nfp: fix getting wrong RSS configuration
       [not found] <20230221055222.38289-1-chaoyong.he@corigine.com>
@ 2023-02-21  5:52 ` Chaoyong He
  0 siblings, 0 replies; only message in thread
From: Chaoyong He @ 2023-02-21  5:52 UTC (permalink / raw)
  To: dev
  Cc: oss-drivers, niklas.soderlund, Long Wu, louis.peens, stable, Chaoyong He

From: Long Wu <long.wu@corigine.com>

"NFP_NET_CFG_RSS_IPV4" and "NFP_NET_CFG_RSS_IPV6" represent that firmware
will calculate RSS base on l3 rather than udp or tcp information from
packets. So the logic of return RSS configuration in driver is wrong.
Modify code to return the right configuration.

Fixes: 934e4c60fbff ("nfp: add RSS")
Cc: louis.peens@corigine.com
Cc: stable@dpdk.org

Signed-off-by: Long Wu <long.wu@corigine.com>
Reviewed-by: Chaoyong He <chaoyong.he@corigine.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund@corigine.com>
---
 drivers/net/nfp/nfp_common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/nfp/nfp_common.c b/drivers/net/nfp/nfp_common.c
index cfc38db65a..a025c67e3b 100644
--- a/drivers/net/nfp/nfp_common.c
+++ b/drivers/net/nfp/nfp_common.c
@@ -1420,7 +1420,7 @@ nfp_net_rss_hash_conf_get(struct rte_eth_dev *dev,
 	cfg_rss_ctrl = nn_cfg_readl(hw, NFP_NET_CFG_RSS_CTRL);
 
 	if (cfg_rss_ctrl & NFP_NET_CFG_RSS_IPV4)
-		rss_hf |= RTE_ETH_RSS_NONFRAG_IPV4_TCP | RTE_ETH_RSS_NONFRAG_IPV4_UDP;
+		rss_hf |= RTE_ETH_RSS_IPV4;
 
 	if (cfg_rss_ctrl & NFP_NET_CFG_RSS_IPV4_TCP)
 		rss_hf |= RTE_ETH_RSS_NONFRAG_IPV4_TCP;
@@ -1435,7 +1435,7 @@ nfp_net_rss_hash_conf_get(struct rte_eth_dev *dev,
 		rss_hf |= RTE_ETH_RSS_NONFRAG_IPV6_UDP;
 
 	if (cfg_rss_ctrl & NFP_NET_CFG_RSS_IPV6)
-		rss_hf |= RTE_ETH_RSS_NONFRAG_IPV4_UDP | RTE_ETH_RSS_NONFRAG_IPV6_UDP;
+		rss_hf |= RTE_ETH_RSS_IPV6;
 
 	if (cfg_rss_ctrl & NFP_NET_CFG_RSS_IPV4_SCTP)
 		rss_hf |= RTE_ETH_RSS_NONFRAG_IPV4_SCTP;
-- 
2.29.3


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-02-21  5:52 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20230221055222.38289-1-chaoyong.he@corigine.com>
2023-02-21  5:52 ` [PATCH 2/2] net/nfp: fix getting wrong RSS configuration Chaoyong He

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).