patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Shani Peretz <shperetz@nvidia.com>
To: Bruce Richardson <bruce.richardson@intel.com>
Cc: Ciara Loftus <ciara.loftus@intel.com>, dpdk stable <stable@dpdk.org>
Subject: patch 'net/ice: fix VLAN tag reporting on Rx' has been queued to stable release 23.11.6
Date: Sun, 21 Dec 2025 16:56:22 +0200	[thread overview]
Message-ID: <20251221145746.763179-34-shperetz@nvidia.com> (raw)
In-Reply-To: <20251221145746.763179-1-shperetz@nvidia.com>

Hi,

FYI, your patch has been queued to stable release 23.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 12/26/25. 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/shanipr/dpdk-stable

This queued commit can be viewed at:
https://github.com/shanipr/dpdk-stable/commit/6c6757f46a247ab11993744fe22aefcfcf68b8f0

Thanks.

Shani

---
From 6c6757f46a247ab11993744fe22aefcfcf68b8f0 Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Thu, 7 Aug 2025 20:08:26 +0100
Subject: [PATCH] net/ice: fix VLAN tag reporting on Rx

[ upstream commit fba64e026d03f4926e1ddc15a2128b8447b73d69 ]

The ice driver expects the first, or outer, VLAN tag in a packet to be
written to the L2TAG1 field of the descriptor, as configured by the
l2tsel field when configuring the queue context initially for the
device. However, when configuring the actual VLAN or QinQ strip
behaviour, that l2tsel field was changed, sending the single/outer vlan
tag to the L2TAG2 field in the descriptor. This meant that it was not
getting picked up correctly by the Rx paths.

This issue has been around for a long time, but was previously
partially hidden by the issue fixed in [1], since due to that bug,
the l2tsel field was not getting overridden in the single-queue case
(since the single queue was the final queue).

Fix the issue by just removing the code updating the l2tsel field, and
leave it as set by default in the initial queue configuration.

[1] commit 4cd8c72f661c ("net/ice: fix inconsistency in Rx queue VLAN tag placement")

Fixes: de5da9d16430 ("net/ice: support double VLAN")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Ciara Loftus <ciara.loftus@intel.com>
---
 drivers/net/ice/ice_ethdev.c | 83 ++----------------------------------
 1 file changed, 3 insertions(+), 80 deletions(-)

diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c
index be826d3108..91609b948d 100644
--- a/drivers/net/ice/ice_ethdev.c
+++ b/drivers/net/ice/ice_ethdev.c
@@ -57,14 +57,6 @@ static const char * const ice_valid_args[] = {
 /* Maximum number of VSI */
 #define ICE_MAX_NUM_VSIS          (768UL)
 
-/* The 119 bit offset of the LAN Rx queue context is the L2TSEL control bit. */
-#define ICE_L2TSEL_QRX_CONTEXT_REG_IDX	3
-#define ICE_L2TSEL_BIT_OFFSET		   23
-enum ice_l2tsel {
-	ICE_L2TSEL_EXTRACT_FIRST_TAG_L2TAG2_2ND,
-	ICE_L2TSEL_EXTRACT_FIRST_TAG_L2TAG1,
-};
-
 struct proto_xtr_ol_flag {
 	const struct rte_mbuf_dynflag param;
 	bool required;
@@ -4721,49 +4713,12 @@ ice_vsi_config_vlan_stripping(struct ice_vsi *vsi, bool ena)
 	return ret;
 }
 
-/**
- * ice_vsi_update_l2tsel - update l2tsel field for all Rx rings on this VSI
- * @vsi: VSI used to update l2tsel on
- * @l2tsel: l2tsel setting requested
- *
- * Use the l2tsel setting to update all of the Rx queue context bits for l2tsel.
- * This will modify which descriptor field the first offloaded VLAN will be
- * stripped into.
- */
-static void ice_vsi_update_l2tsel(struct ice_vsi *vsi, enum ice_l2tsel l2tsel)
-{
-	struct ice_hw *hw = ICE_VSI_TO_HW(vsi);
-	struct ice_pf *pf = ICE_VSI_TO_PF(vsi);
-	struct rte_eth_dev_data *dev_data = pf->dev_data;
-	u32 l2tsel_bit;
-	uint16_t i;
-
-	if (l2tsel == ICE_L2TSEL_EXTRACT_FIRST_TAG_L2TAG2_2ND)
-		l2tsel_bit = 0;
-	else
-		l2tsel_bit = BIT(ICE_L2TSEL_BIT_OFFSET);
-
-	for (i = 0; i < dev_data->nb_rx_queues; i++) {
-		u32 qrx_context_offset;
-		u32 regval;
-
-		qrx_context_offset =
-			QRX_CONTEXT(ICE_L2TSEL_QRX_CONTEXT_REG_IDX, i);
-
-		regval = rd32(hw, qrx_context_offset);
-		regval &= ~BIT(ICE_L2TSEL_BIT_OFFSET);
-		regval |= l2tsel_bit;
-		wr32(hw, qrx_context_offset, regval);
-	}
-}
-
 /* Configure outer vlan stripping on or off in QinQ mode */
 static int
 ice_vsi_config_outer_vlan_stripping(struct ice_vsi *vsi, bool on)
 {
 	uint16_t outer_ethertype = vsi->adapter->pf.outer_ethertype;
 	struct ice_hw *hw = ICE_VSI_TO_HW(vsi);
-	int err = 0;
 
 	if (vsi->vsi_id >= ICE_MAX_NUM_VSIS) {
 		PMD_DRV_LOG(ERR, "VSI ID exceeds the maximum");
@@ -4775,41 +4730,9 @@ ice_vsi_config_outer_vlan_stripping(struct ice_vsi *vsi, bool on)
 		return -EOPNOTSUPP;
 	}
 
-	if (on) {
-		err = ice_vsi_ena_outer_stripping(vsi, outer_ethertype);
-		if (!err) {
-			enum ice_l2tsel l2tsel =
-				ICE_L2TSEL_EXTRACT_FIRST_TAG_L2TAG2_2ND;
-
-			/* PF tells the VF that the outer VLAN tag is always
-			 * extracted to VIRTCHNL_VLAN_TAG_LOCATION_L2TAG2_2 and
-			 * inner is always extracted to
-			 * VIRTCHNL_VLAN_TAG_LOCATION_L2TAG1. This is needed to
-			 * support outer stripping so the first tag always ends
-			 * up in L2TAG2_2ND and the second/inner tag, if
-			 * enabled, is extracted in L2TAG1.
-			 */
-			ice_vsi_update_l2tsel(vsi, l2tsel);
-		}
-	} else {
-		err = ice_vsi_dis_outer_stripping(vsi);
-		if (!err) {
-			enum ice_l2tsel l2tsel =
-				ICE_L2TSEL_EXTRACT_FIRST_TAG_L2TAG1;
-
-			/* PF tells the VF that the outer VLAN tag is always
-			 * extracted to VIRTCHNL_VLAN_TAG_LOCATION_L2TAG2_2 and
-			 * inner is always extracted to
-			 * VIRTCHNL_VLAN_TAG_LOCATION_L2TAG1. This is needed to
-			 * support inner stripping while outer stripping is
-			 * disabled so that the first and only tag is extracted
-			 * in L2TAG1.
-			 */
-			ice_vsi_update_l2tsel(vsi, l2tsel);
-		}
-	}
-
-	return err;
+	return on ?
+		ice_vsi_ena_outer_stripping(vsi, outer_ethertype) :
+		ice_vsi_dis_outer_stripping(vsi);
 }
 
 static int
-- 
2.43.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2025-12-21 16:54:19.096969745 +0200
+++ 0034-net-ice-fix-VLAN-tag-reporting-on-Rx.patch	2025-12-21 16:54:16.969059000 +0200
@@ -1 +1 @@
-From fba64e026d03f4926e1ddc15a2128b8447b73d69 Mon Sep 17 00:00:00 2001
+From 6c6757f46a247ab11993744fe22aefcfcf68b8f0 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit fba64e026d03f4926e1ddc15a2128b8447b73d69 ]
+
@@ -25 +26,0 @@
-Cc: stable@dpdk.org
@@ -30 +31 @@
- drivers/net/intel/ice/ice_ethdev.c | 83 ++----------------------------
+ drivers/net/ice/ice_ethdev.c | 83 ++----------------------------------
@@ -33,5 +34,5 @@
-diff --git a/drivers/net/intel/ice/ice_ethdev.c b/drivers/net/intel/ice/ice_ethdev.c
-index 513777e372..6c65a8341a 100644
---- a/drivers/net/intel/ice/ice_ethdev.c
-+++ b/drivers/net/intel/ice/ice_ethdev.c
-@@ -65,14 +65,6 @@ static const char * const ice_valid_args[] = {
+diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c
+index be826d3108..91609b948d 100644
+--- a/drivers/net/ice/ice_ethdev.c
++++ b/drivers/net/ice/ice_ethdev.c
+@@ -57,14 +57,6 @@ static const char * const ice_valid_args[] = {
@@ -52 +53 @@
-@@ -4965,49 +4957,12 @@ ice_vsi_config_vlan_stripping(struct ice_vsi *vsi, bool ena)
+@@ -4721,49 +4713,12 @@ ice_vsi_config_vlan_stripping(struct ice_vsi *vsi, bool ena)
@@ -79 +79,0 @@
--		const struct ci_rx_queue *rxq = dev_data->rx_queues[i];
@@ -83 +83,2 @@
--		qrx_context_offset = QRX_CONTEXT(ICE_L2TSEL_QRX_CONTEXT_REG_IDX, rxq->reg_idx);
+-		qrx_context_offset =
+-			QRX_CONTEXT(ICE_L2TSEL_QRX_CONTEXT_REG_IDX, i);
@@ -102 +103 @@
-@@ -5019,41 +4974,9 @@ ice_vsi_config_outer_vlan_stripping(struct ice_vsi *vsi, bool on)
+@@ -4775,41 +4730,9 @@ ice_vsi_config_outer_vlan_stripping(struct ice_vsi *vsi, bool on)

  parent reply	other threads:[~2025-12-21 15:01 UTC|newest]

Thread overview: 93+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-12-21 14:55 patch 'test/telemetry: fix test calling all commands' " Shani Peretz
2025-12-21 14:55 ` patch 'eal: fix plugin dir walk' " Shani Peretz
2025-12-21 14:55 ` patch 'cmdline: fix port list parsing' " Shani Peretz
2025-12-21 14:55 ` patch 'cmdline: fix highest bit " Shani Peretz
2025-12-21 14:55 ` patch 'tailq: fix lookup macro' " Shani Peretz
2025-12-21 14:55 ` patch 'hash: fix unaligned access in predictable RSS' " Shani Peretz
2025-12-21 14:55 ` patch 'graph: fix unaligned access in stats' " Shani Peretz
2025-12-21 14:55 ` patch 'eventdev: fix listing timer adapters with telemetry' " Shani Peretz
2025-12-21 14:55 ` patch 'cfgfile: fix section count with no name' " Shani Peretz
2025-12-21 14:55 ` patch 'net/gve: do not write zero-length descriptors' " Shani Peretz
2025-12-21 14:55 ` patch 'net/gve: validate Tx packet before sending' " Shani Peretz
2025-12-21 14:56 ` patch 'net/vmxnet3: fix mapping of mempools to queues' " Shani Peretz
2025-12-21 14:56 ` patch 'app/testpmd: increase size of set cores list command' " Shani Peretz
2025-12-21 14:56 ` patch 'net/dpaa2: fix shaper rate' " Shani Peretz
2025-12-21 14:56 ` patch 'app/testpmd: monitor state of primary process' " Shani Peretz
2025-12-21 14:56 ` patch 'net/gve: fix disabling interrupts on DQ' " Shani Peretz
2025-12-21 14:56 ` patch 'app/testpmd: fix conntrack action query' " Shani Peretz
2025-12-21 14:56 ` patch 'doc: add conntrack state inspect command to testpmd guide' " Shani Peretz
2025-12-21 14:56 ` patch 'net/gve: free Rx mbufs if allocation fails on ring setup' " Shani Peretz
2025-12-21 14:56 ` patch 'app/testpmd: validate DSCP and VLAN for meter creation' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix min and max MTU reporting' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix storage of shared Rx queues' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5/hws: fix ESP header match in strict mode' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix unsupported flow rule port action' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix non-template age rules flush' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix connection tracking state item validation' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5/hws: fix TIR action support in FDB' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix indirect flow age action handling' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix Direct Verbs counter offset detection' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix interface name parameter definition' " Shani Peretz
2025-12-21 14:56 ` patch 'net/iavf: fix Tx vector path selection logic' " Shani Peretz
2025-12-21 14:56 ` patch 'net/ice: fix vector Rx VLAN offload flags' " Shani Peretz
2025-12-21 14:56 ` patch 'net/intel: fix assumption about tag placement order' " Shani Peretz
2025-12-21 14:56 ` Shani Peretz [this message]
2025-12-21 14:56 ` patch 'net/ice/base: fix adding special words' " Shani Peretz
2025-12-21 14:56 ` patch 'net/ice/base: fix memory leak in HW profile handling' " Shani Peretz
2025-12-21 14:56 ` patch 'net/ice/base: fix memory leak in recipe " Shani Peretz
2025-12-21 14:56 ` patch 'gro: fix payload corruption in coalescing packets' " Shani Peretz
2025-12-21 14:56 ` patch 'eal: fix DMA mask validation with IOVA mode option' " Shani Peretz
2025-12-21 14:56 ` patch 'eal: fix MP socket cleanup' " Shani Peretz
2025-12-21 14:56 ` patch 'crypto/ipsec_mb: fix QP release in secondary' " Shani Peretz
2025-12-21 14:56 ` patch 'efd: fix AVX2 support' " Shani Peretz
2025-12-21 14:56 ` patch 'net/octeon_ep: fix device start' " Shani Peretz
2025-12-21 14:56 ` patch 'common/cnxk: fix async event handling' " Shani Peretz
2025-12-21 14:56 ` patch 'doc: fix feature list of ice driver' " Shani Peretz
2025-12-21 14:56 ` patch 'doc: fix feature list of iavf " Shani Peretz
2025-12-21 14:56 ` patch 'baseband/acc: fix exported header' " Shani Peretz
2025-12-21 14:56 ` patch 'eventdev: do not include driver header in DMA adapter' " Shani Peretz
2025-12-21 14:56 ` patch 'gpudev: fix driver header for Windows' " Shani Peretz
2025-12-21 14:56 ` patch 'drivers: fix some exported headers' " Shani Peretz
2025-12-21 14:56 ` patch 'test/debug: fix crash with mlx5 devices' " Shani Peretz
2025-12-21 14:56 ` patch 'bus/pci: fix build with MinGW 13' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: " Shani Peretz
2025-12-21 14:56 ` patch 'dma/hisilicon: fix stop with pending transfers' " Shani Peretz
2025-12-21 14:56 ` patch 'test/dma: fix failure condition' " Shani Peretz
2025-12-21 14:56 ` patch 'eal/x86: enable timeout in AMD power monitor' " Shani Peretz
2025-12-21 14:56 ` patch 'fib6: fix tbl8 allocation check logic' " Shani Peretz
2025-12-21 14:56 ` patch 'vhost: add VDUSE virtqueue ready state polling workaround' " Shani Peretz
2025-12-21 14:56 ` patch 'vhost: fix virtqueue info init in VDUSE vring setup' " Shani Peretz
2025-12-21 14:56 ` patch 'vhost: fix double fetch when dequeue offloading' " Shani Peretz
2025-12-21 14:56 ` patch 'net/ice/base: fix integer overflow on NVM init' " Shani Peretz
2025-12-21 14:56 ` patch 'doc: fix display of commands in cpfl guide' " Shani Peretz
2025-12-21 14:56 ` patch 'net/ice: fix initialization with 8 ports' " Shani Peretz
2025-12-21 14:56 ` patch 'net/ice: remove indirection for FDIR filters' " Shani Peretz
2025-12-21 14:56 ` patch 'net/ice: fix memory leak in raw pattern parse' " Shani Peretz
2025-12-21 14:56 ` patch 'net/i40e: fix symmetric Toeplitz hashing for SCTP' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5/hws: fix ESP header match in strict mode' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix ESP header match after UDP for group 0' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix multicast' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix indirect flow action memory leak' " Shani Peretz
2025-12-21 14:56 ` patch 'net/mlx5: fix MTU initialization' " Shani Peretz
2025-12-21 14:57 ` patch 'net/mlx5: fix leak of flow indexed pools' " Shani Peretz
2025-12-21 14:57 ` patch 'net/hns3: fix inconsistent lock' " Shani Peretz
2025-12-21 14:57 ` patch 'net/hns3: fix VLAN resources freeing' " Shani Peretz
2025-12-21 14:57 ` patch 'net/hns3: fix overwrite mbuf in vector path' " Shani Peretz
2025-12-21 14:57 ` patch 'net/af_packet: fix crash in secondary process' " Shani Peretz
2025-12-21 14:57 ` patch 'net/ark: remove double mbuf free' " Shani Peretz
2025-12-21 14:57 ` patch 'app/testpmd: stop forwarding in secondary process' " Shani Peretz
2025-12-21 14:57 ` patch 'net/tap: fix build with LTO' " Shani Peretz
2025-12-21 14:57 ` patch 'net/hns3: fix VLAN tag loss for short tunnel frame' " Shani Peretz
2025-12-21 14:57 ` patch 'ethdev: fix VLAN filter parameter description' " Shani Peretz
2025-12-21 14:57 ` patch 'net/enetfec: fix file descriptor leak on read error' " Shani Peretz
2025-12-21 14:57 ` patch 'net/enetfec: fix out-of-bounds access in UIO mapping' " Shani Peretz
2025-12-21 14:57 ` patch 'net/enetfec: fix buffer descriptor size configuration' " Shani Peretz
2025-12-21 14:57 ` patch 'net/enetfec: fix Tx queue free' " Shani Peretz
2025-12-21 14:57 ` patch 'net/enetfec: fix checksum flag handling and error return' " Shani Peretz
2025-12-21 14:57 ` patch 'net/enetfec: reject multi-queue configuration' " Shani Peretz
2025-12-21 14:57 ` patch 'net/enetfec: fix memory leak in Rx buffer cleanup' " Shani Peretz
2025-12-21 14:57 ` patch 'net/enetfec: reject Tx deferred queue' " Shani Peretz
2025-12-21 14:57 ` patch 'net/tap: fix interrupt callback crash after failed start' " Shani Peretz
2025-12-21 14:57 ` patch 'net/ena: fix PCI BAR mapping on 64K page size' " Shani Peretz
2025-12-21 14:57 ` patch 'net/ena/base: fix unsafe memcpy on invalid memory' " Shani Peretz
2025-12-21 14:57 ` patch 'net/dpaa2: fix uninitialized variable' " Shani Peretz

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=20251221145746.763179-34-shperetz@nvidia.com \
    --to=shperetz@nvidia.com \
    --cc=bruce.richardson@intel.com \
    --cc=ciara.loftus@intel.com \
    --cc=stable@dpdk.org \
    /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).