From: Jie Wang <jie1x.wang@intel.com>
To: dev@dpdk.org
Cc: yuying.zhang@intel.com, xiaoyun.li@intel.com,
stevex.yang@intel.com, junfeng.guo@intel.com,
qi.z.zhang@intel.com, Jie Wang <jie1x.wang@intel.com>
Subject: [dpdk-dev] [PATCH v2] app/testpmd: fix set Rx offloads RSS hash off
Date: Thu, 4 Nov 2021 17:29:47 +0800 [thread overview]
Message-ID: <20211104092947.244962-1-jie1x.wang@intel.com> (raw)
In-Reply-To: <20211103030705.211093-1-jie1x.wang@intel.com>
When we set Rx offloads RSS hash off in cmdline, then we start
port, if dev->data->dev_conf.rxmode.mq_mode RSS enable(multiple
queues mode), it will load RSS hash in driver and sync to port.
After setting Rx offloads RSS hash off, this patch removes
RTE_ETH_MQ_RX_RSS in port->dev_conf.rxmode.mq_mode to fix this issue.
And after setting Rx offloads RSS hash on, this patch also adds
RTE_ETH_MQ_RX_RSS in port->dev_conf.rxmode.mq_mode.
Fixes: c73a9071877a ("app/testpmd: add commands to test new offload API")
Signed-off-by: Jie Wang <jie1x.wang@intel.com>
---
app/test-pmd/cmdline.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index d08a1c9777..f8277e4443 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -16176,10 +16176,16 @@ cmd_config_per_port_rx_offload_parsed(void *parsed_result,
port->dev_conf.rxmode.offloads |= single_offload;
for (q = 0; q < nb_rx_queues; q++)
port->rx_conf[q].offloads |= single_offload;
+
+ if (single_offload & 0x80000)
+ port->dev_conf.rxmode.mq_mode |= RTE_ETH_MQ_RX_RSS;
} else {
port->dev_conf.rxmode.offloads &= ~single_offload;
for (q = 0; q < nb_rx_queues; q++)
port->rx_conf[q].offloads &= ~single_offload;
+
+ if (single_offload & 0x80000)
+ port->dev_conf.rxmode.mq_mode &= ~RTE_ETH_MQ_RX_RSS;
}
cmd_reconfig_device_queue(port_id, 1, 1);
--
2.25.1
next prev parent reply other threads:[~2021-11-04 9:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-03 3:07 [dpdk-dev] [PATCH] " Jie Wang
2021-11-04 9:29 ` Jie Wang [this message]
2021-11-05 16:24 ` [dpdk-dev] [PATCH v2] " Ferruh Yigit
2021-11-08 7:24 ` Wang, Jie1X
2021-11-08 9:02 ` Ferruh Yigit
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=20211104092947.244962-1-jie1x.wang@intel.com \
--to=jie1x.wang@intel.com \
--cc=dev@dpdk.org \
--cc=junfeng.guo@intel.com \
--cc=qi.z.zhang@intel.com \
--cc=stevex.yang@intel.com \
--cc=xiaoyun.li@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).