patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Kevin Traynor <ktraynor@redhat.com>
To: Edwin Brossette <edwin.brossette@6wind.com>
Cc: Vladimir Medvedkin <vladimir.medvedkin@intel.com>,
	dpdk stable <stable@dpdk.org>
Subject: patch 'net/ixgbevf: fix RSS init for x550 NICs' has been queued to stable release 21.11.7
Date: Fri,  8 Mar 2024 14:28:00 +0000	[thread overview]
Message-ID: <20240308142824.528417-12-ktraynor@redhat.com> (raw)
In-Reply-To: <20240308142824.528417-1-ktraynor@redhat.com>

Hi,

FYI, your patch has been queued to stable release 21.11.7

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/13/24. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/153ce28fcff59b6cf80b94c45811244cdb847f7e

Thanks.

Kevin

---
From 153ce28fcff59b6cf80b94c45811244cdb847f7e Mon Sep 17 00:00:00 2001
From: Edwin Brossette <edwin.brossette@6wind.com>
Date: Thu, 15 Feb 2024 14:31:45 +0100
Subject: [PATCH] net/ixgbevf: fix RSS init for x550 NICs

[ upstream commit 3a53577d5f390e8635a672b79616e54c59b330ab ]

Different Intel NICs with the igxbe PMD do not handle RSS in the same
way when working with virtualization. While some NICs like Intel 82599ES
only have a single RSS table in the device and leave all RSS features to
be handled by the PF, some other NICs like x550 let the VF handle RSS
features. This can lead to different behavior when RSS is enabled
depending on the model of nic used.

In particular, ixgbevf_dev_rx_init() does not configure RSS parameters
at device init, even if the multi-queue mode option is set in the device
configuration (ie. RTE_ETH_MQ_RX_RSS is set). Note that this issue went
unnoticed until now, probably because some NICs do not really have
support for RSS in virtualization mode.

Thus, depending on the NIC used, we can we find ourselves in a situation
where RSS is not configured despite being enabled. This will cause
serious performance issues because the RSS RETA table will be fully
zeroed, causing all packets to go only to the first queue, leaving all
other queues empty.

By looking at ixgbe_reta_size_get(), we can see that only X550 NIC
models have a non zero RETA size set in VF mode. Therefore, add a call
to ixgbe_rss_configure() for these cards in ixgbevf_dev_rx_init() if the
option to enable RSS is set.

Fixes: f4d1598ee14f ("ixgbevf: support RSS config on x550")

Signed-off-by: Edwin Brossette <edwin.brossette@6wind.com>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
---
 drivers/net/ixgbe/ixgbe_rxtx.c | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/drivers/net/ixgbe/ixgbe_rxtx.c b/drivers/net/ixgbe/ixgbe_rxtx.c
index c137707869..e3c611a40f 100644
--- a/drivers/net/ixgbe/ixgbe_rxtx.c
+++ b/drivers/net/ixgbe/ixgbe_rxtx.c
@@ -5742,4 +5742,23 @@ ixgbevf_dev_rx_init(struct rte_eth_dev *dev)
 	IXGBE_WRITE_REG(hw, IXGBE_VFPSRTYPE, psrtype);
 
+	/* Initialize the rss for x550_vf cards if enabled */
+	switch (hw->mac.type) {
+	case ixgbe_mac_X550_vf:
+	case ixgbe_mac_X550EM_x_vf:
+	case ixgbe_mac_X550EM_a_vf:
+		switch (dev->data->dev_conf.rxmode.mq_mode) {
+		case RTE_ETH_MQ_RX_RSS:
+		case RTE_ETH_MQ_RX_DCB_RSS:
+		case RTE_ETH_MQ_RX_VMDQ_RSS:
+			ixgbe_rss_configure(dev);
+			break;
+		default:
+			break;
+		}
+		break;
+	default:
+		break;
+	}
+
 	ixgbe_set_rx_function(dev);
 
-- 
2.43.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-03-08 13:47:49.407409035 +0000
+++ 0012-net-ixgbevf-fix-RSS-init-for-x550-NICs.patch	2024-03-08 13:47:49.003686619 +0000
@@ -1 +1 @@
-From 3a53577d5f390e8635a672b79616e54c59b330ab Mon Sep 17 00:00:00 2001
+From 153ce28fcff59b6cf80b94c45811244cdb847f7e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 3a53577d5f390e8635a672b79616e54c59b330ab ]
+
@@ -31 +32,0 @@
-Cc: stable@dpdk.org
@@ -40 +41 @@
-index 90b0a7004f..f6c17d4efb 100644
+index c137707869..e3c611a40f 100644
@@ -43 +44 @@
-@@ -5845,4 +5845,23 @@ ixgbevf_dev_rx_init(struct rte_eth_dev *dev)
+@@ -5742,4 +5742,23 @@ ixgbevf_dev_rx_init(struct rte_eth_dev *dev)


  parent reply	other threads:[~2024-03-08 14:31 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-08 14:27 patch 'doc: fix configuration in baseband 5GNR driver guide' " Kevin Traynor
2024-03-08 14:27 ` patch 'event/dlb2: remove superfluous memcpy' " Kevin Traynor
2024-03-08 14:27 ` patch 'test/event: fix crash in Tx adapter freeing' " Kevin Traynor
2024-03-08 14:27 ` patch 'eventdev: improve Doxygen comments on configure struct' " Kevin Traynor
2024-03-08 14:27 ` patch 'eventdev: fix Doxygen processing of vector " Kevin Traynor
2024-03-08 14:27 ` patch 'app/crypto-perf: fix out-of-place mbuf size' " Kevin Traynor
2024-03-08 14:27 ` patch 'app/crypto-perf: add missing op resubmission' " Kevin Traynor
2024-03-08 14:27 ` patch 'doc: fix typos in cryptodev overview' " Kevin Traynor
2024-03-08 14:27 ` patch 'net/tap: do not overwrite flow API errors' " Kevin Traynor
2024-03-08 14:27 ` patch 'net/tap: fix traffic control handle calculation' " Kevin Traynor
2024-03-08 14:27 ` patch 'net/bnxt: fix null pointer dereference' " Kevin Traynor
2024-03-08 14:28 ` Kevin Traynor [this message]
2024-03-08 14:28 ` patch 'net/iavf: remove error logs for VLAN offloading' " Kevin Traynor
2024-03-08 14:28 ` patch 'net/ixgbe: increase VF reset timeout' " Kevin Traynor
2024-03-08 14:28 ` patch 'net/i40e: remove incorrect 16B descriptor read block' " Kevin Traynor
2024-03-08 14:28 ` patch 'net/iavf: " Kevin Traynor
2024-03-08 14:28 ` patch 'net/ice: " Kevin Traynor
2024-03-08 14:28 ` patch 'net/bnx2x: fix warnings about memcpy lengths' " Kevin Traynor
2024-03-08 14:28 ` patch 'common/cnxk: fix Tx MTU configuration' " Kevin Traynor
2024-03-08 14:28 ` patch 'net/cnxk: fix MTU limit' " Kevin Traynor
2024-03-08 14:28 ` patch 'common/cnxk: fix RSS RETA configuration' " Kevin Traynor
2024-03-08 14:28 ` patch 'common/cnxk: fix mbox struct attributes' " Kevin Traynor
2024-03-08 14:28 ` patch 'common/cnxk: fix possible out-of-bounds access' " Kevin Traynor
2024-03-08 14:28 ` patch 'net/mlx5: fix use after free when releasing Tx queues' " Kevin Traynor
2024-03-08 14:28 ` patch 'net/mlx5: fix error packets drop in regular Rx' " Kevin Traynor
2024-03-08 14:28 ` patch 'net/mlx5: fix VLAN handling in meter split' " Kevin Traynor
2024-03-08 14:28 ` patch 'net/mlx5: fix counters map in bonding mode' " Kevin Traynor
2024-03-08 14:28 ` patch 'test: fix probing in secondary process' " Kevin Traynor
2024-03-08 14:28 ` patch 'bus/vdev: fix devargs " Kevin Traynor
2024-03-08 14:28 ` patch 'config: fix CPU instruction set for cross-build' " Kevin Traynor
2024-03-08 14:28 ` patch 'test/mbuf: fix external mbuf case with assert enabled' " Kevin Traynor
2024-03-08 14:28 ` patch 'test: do not count skipped tests as executed' " Kevin Traynor
2024-03-08 14:28 ` patch 'examples/packet_ordering: fix Rx with reorder mode disabled' " Kevin Traynor
2024-03-08 14:28 ` patch 'examples/l3fwd: fix Rx over not ready port' " Kevin Traynor

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=20240308142824.528417-12-ktraynor@redhat.com \
    --to=ktraynor@redhat.com \
    --cc=edwin.brossette@6wind.com \
    --cc=stable@dpdk.org \
    --cc=vladimir.medvedkin@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).