patches for DPDK stable branches
 help / color / mirror / Atom feed
* [PATCH 19.11] app/testpmd: fix DCB in VT configuration
@ 2021-12-08 10:39 Jie Wang
  2021-12-08 14:20 ` Christian Ehrhardt
  0 siblings, 1 reply; 2+ messages in thread
From: Jie Wang @ 2021-12-08 10:39 UTC (permalink / raw)
  To: stable; +Cc: Jie Wang, Aman Singh

[ upstream commit cbe70fded831acac4ccbde8e11ba33ce8c24227c ]

When set port DCB in VT mode enabled, it should remove RSS HASH
offload before reconfiguring the device and queues.

Because port multi-queue mode is changed from RSS to DCB in VT.

Fixes: 2a977b891f99 ("app/testpmd: fix DCB configuration")

Signed-off-by: Jie Wang <jie1x.wang@intel.com>
Acked-by: Aman Singh <aman.deep.singh@intel.com>
---
 app/test-pmd/testpmd.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index dca10e7b66..b0b7472e91 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -3484,6 +3484,13 @@ init_port_dcb_config(portid_t pid,
 	if (retval < 0)
 		return retval;
 	port_conf.rxmode.offloads |= DEV_RX_OFFLOAD_VLAN_FILTER;
+	/* remove RSS HASH offload for DCB in vt mode */
+	if (port_conf.rxmode.mq_mode == ETH_MQ_RX_VMDQ_DCB) {
+		port_conf.rxmode.offloads &= ~DEV_RX_OFFLOAD_RSS_HASH;
+		for (i = 0; i < nb_rxq; i++)
+			rte_port->rx_conf[i].offloads &=
+				~DEV_RX_OFFLOAD_RSS_HASH;
+	}
 
 	/* re-configure the device . */
 	retval = rte_eth_dev_configure(pid, nb_rxq, nb_rxq, &port_conf);
-- 
2.25.1


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

* Re: [PATCH 19.11] app/testpmd: fix DCB in VT configuration
  2021-12-08 10:39 [PATCH 19.11] app/testpmd: fix DCB in VT configuration Jie Wang
@ 2021-12-08 14:20 ` Christian Ehrhardt
  0 siblings, 0 replies; 2+ messages in thread
From: Christian Ehrhardt @ 2021-12-08 14:20 UTC (permalink / raw)
  To: Jie Wang; +Cc: stable, Aman Singh

On Wed, Dec 8, 2021 at 3:43 AM Jie Wang <jie1x.wang@intel.com> wrote:
>
> [ upstream commit cbe70fded831acac4ccbde8e11ba33ce8c24227c ]

Thanks, applied

> When set port DCB in VT mode enabled, it should remove RSS HASH
> offload before reconfiguring the device and queues.
>
> Because port multi-queue mode is changed from RSS to DCB in VT.
>
> Fixes: 2a977b891f99 ("app/testpmd: fix DCB configuration")
>
> Signed-off-by: Jie Wang <jie1x.wang@intel.com>
> Acked-by: Aman Singh <aman.deep.singh@intel.com>
> ---
>  app/test-pmd/testpmd.c | 7 +++++++
>  1 file changed, 7 insertions(+)
>
> diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
> index dca10e7b66..b0b7472e91 100644
> --- a/app/test-pmd/testpmd.c
> +++ b/app/test-pmd/testpmd.c
> @@ -3484,6 +3484,13 @@ init_port_dcb_config(portid_t pid,
>         if (retval < 0)
>                 return retval;
>         port_conf.rxmode.offloads |= DEV_RX_OFFLOAD_VLAN_FILTER;
> +       /* remove RSS HASH offload for DCB in vt mode */
> +       if (port_conf.rxmode.mq_mode == ETH_MQ_RX_VMDQ_DCB) {
> +               port_conf.rxmode.offloads &= ~DEV_RX_OFFLOAD_RSS_HASH;
> +               for (i = 0; i < nb_rxq; i++)
> +                       rte_port->rx_conf[i].offloads &=
> +                               ~DEV_RX_OFFLOAD_RSS_HASH;
> +       }
>
>         /* re-configure the device . */
>         retval = rte_eth_dev_configure(pid, nb_rxq, nb_rxq, &port_conf);
> --
> 2.25.1
>


-- 
Christian Ehrhardt
Staff Engineer, Ubuntu Server
Canonical Ltd

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

end of thread, other threads:[~2021-12-08 14:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-08 10:39 [PATCH 19.11] app/testpmd: fix DCB in VT configuration Jie Wang
2021-12-08 14:20 ` Christian Ehrhardt

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