DPDK patches and discussions
 help / color / mirror / Atom feed
From: beilei.xing@intel.com
To: jingjing.wu@intel.com, yuying.zhang@intel.com
Cc: dev@dpdk.org, Beilei Xing <beilei.xing@intel.com>
Subject: [PATCH] net/cpfl: fix fail to re-configure RSS
Date: Fri, 16 Jun 2023 12:00:03 +0000	[thread overview]
Message-ID: <20230616120003.41187-1-beilei.xing@intel.com> (raw)

From: Beilei Xing <beilei.xing@intel.com>

Currently, if launch testpmd with multiple queues and re-configure
rxq with 'port config all rxq 1', Rx queue 0 may not receive packets.
that's because RSS lookup tale is not re-configured when Rxq number
is 1.
Although Rxq number is 1 and multi queue mode is RTE_ETH_MQ_RX_NONE,
cpfl PMD should init RSS to allow RSS re-configuration.

Fixes: cfbc66551a14 ("net/cpfl: support RSS")

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
---
 drivers/net/cpfl/cpfl_ethdev.c | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/drivers/net/cpfl/cpfl_ethdev.c b/drivers/net/cpfl/cpfl_ethdev.c
index e96bf0a82e..9755ffe508 100644
--- a/drivers/net/cpfl/cpfl_ethdev.c
+++ b/drivers/net/cpfl/cpfl_ethdev.c
@@ -712,17 +712,15 @@ cpfl_dev_configure(struct rte_eth_dev *dev)
 		return -EINVAL;
 	}
 
-	if (base->caps.rss_caps != 0 && dev->data->nb_rx_queues != 0 &&
-		conf->rxmode.mq_mode == RTE_ETH_MQ_RX_RSS) {
+	if (base->caps.rss_caps != 0 && dev->data->nb_rx_queues != 0) {
 		ret = cpfl_init_rss(vport);
 		if (ret != 0) {
 			PMD_INIT_LOG(ERR, "Failed to init rss");
 			return ret;
 		}
-	} else {
+	} else if (conf->rxmode.mq_mode == RTE_ETH_MQ_RX_RSS) {
 		PMD_INIT_LOG(ERR, "RSS is not supported.");
-		if (conf->rxmode.mq_mode == RTE_ETH_MQ_RX_RSS)
-			return -ENOTSUP;
+		return -ENOTSUP;
 	}
 
 	vport->max_pkt_len =
-- 
2.34.1


             reply	other threads:[~2023-06-16  3:42 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-16 12:00 beilei.xing [this message]
2023-06-16  8:40 ` Wu, Jingjing
2023-06-19  0:44   ` Zhang, Qi Z

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=20230616120003.41187-1-beilei.xing@intel.com \
    --to=beilei.xing@intel.com \
    --cc=dev@dpdk.org \
    --cc=jingjing.wu@intel.com \
    --cc=yuying.zhang@intel.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).