patch 'net/iavf: fix VLAN strip setting after enabling filter' has been queued to stable release 23.11.5
Amiya Ranjan Mohakud
amiyaranjan.mohakud at gmail.com
Wed Jul 30 17:23:48 CEST 2025
Thanks Xueming for taking care of this.
Does it mean it will automatically go to other stable branches also, like
22.11.x ?
Thanks
Amiya
On Wed, 30 Jul 2025 at 20:30, Xueming Li <xuemingl at nvidia.com> wrote:
> Hi,
>
> FYI, your patch has been queued to stable release 23.11.5
>
> Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
> It will be pushed if I get no objections before 08/10/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://git.dpdk.org/dpdk-stable/log/?h=23.11-staging
>
> This queued commit can be viewed at:
>
> https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=f2c11a141c46c6a9d461493b70490940d8147680
>
> Thanks.
>
> Xueming Li <xuemingl at nvidia.com>
>
> ---
> From f2c11a141c46c6a9d461493b70490940d8147680 Mon Sep 17 00:00:00 2001
> From: Amiya Ranjan Mohakud <amiyaranjan.mohakud at gmail.com>
> Date: Mon, 23 Jun 2025 23:41:36 +0530
> Subject: [PATCH] net/iavf: fix VLAN strip setting after enabling filter
> Cc: Xueming Li <xuemingl at nvidia.com>
>
> [ upstream commit 3bfad066f9b4764981c9ad90a750fa6f1afcf15a ]
>
> For i40e kernel drivers which support either vlan(v1) or vlan(v2)
> VIRTCHNL OP, it will set strip on when setting filter on.
> But DPDK side will not change strip flag.
> To be consistent with DPDL side, explicitly disable strip again.
>
> Bugzilla ID: 1725
> Fixes: e25c7ed114b2 ("net/iavf: fix VLAN offload strip flag")
> Cc: stable at dpdk.org
>
> Signed-off-by: Amiya Ranjan Mohakud <amiyaranjan.mohakud at gmail.com>
> Reviewed-by: Ciara Loftus <ciara.loftus at intel.com>
> ---
> .mailmap | 1 +
> drivers/net/iavf/iavf_ethdev.c | 48 ++++++++++++++++++++--------------
> 2 files changed, 30 insertions(+), 19 deletions(-)
>
> diff --git a/.mailmap b/.mailmap
> index e17823a260..80c6f855dc 100644
> --- a/.mailmap
> +++ b/.mailmap
> @@ -84,6 +84,7 @@ Amir Avivi <amir.avivi at intel.com>
> Amit Bernstein <amitbern at amazon.com>
> Amit Gupta <agupta3 at marvell.com>
> Amit Prakash Shukla <amitprakashs at marvell.com>
> +Amiya Ranjan Mohakud <amiyaranjan.mohakud at gmail.com>
> Amr Mokhtar <amr.mokhtar at intel.com>
> Amruta Zende <amruta.zende at intel.com>
> Amrutha Sampath <amrutha.sampath at intel.com>
> diff --git a/drivers/net/iavf/iavf_ethdev.c
> b/drivers/net/iavf/iavf_ethdev.c
> index 4472fd2c2d..391ba2c812 100644
> --- a/drivers/net/iavf/iavf_ethdev.c
> +++ b/drivers/net/iavf/iavf_ethdev.c
> @@ -1364,13 +1364,38 @@ iavf_dev_del_mac_addr(struct rte_eth_dev *dev,
> uint32_t index)
> vf->mac_num--;
> }
>
> +static int
> +iavf_disable_vlan_strip_ex(struct rte_eth_dev *dev, int on)
> +{
> + /* For i40e kernel drivers which supports both vlan(v1 & v2)
> VIRTCHNL OP,
> + * it will set strip on when setting filter on but dpdk side will
> not
> + * change strip flag. To be consistent with dpdk side, explicitly
> disable
> + * strip again.
> + *
> + */
> + struct iavf_adapter *adapter =
> + IAVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private);
> + struct rte_eth_conf *dev_conf = &dev->data->dev_conf;
> + int err;
> +
> + if (adapter->hw.mac.type == IAVF_MAC_XL710 ||
> + adapter->hw.mac.type == IAVF_MAC_VF ||
> + adapter->hw.mac.type == IAVF_MAC_X722_VF) {
> + if (on && !(dev_conf->rxmode.offloads &
> RTE_ETH_RX_OFFLOAD_VLAN_STRIP)) {
> + err = iavf_disable_vlan_strip(adapter);
> + if (err)
> + return -EIO;
> + }
> + }
> + return 0;
> +}
> +
> static int
> iavf_dev_vlan_filter_set(struct rte_eth_dev *dev, uint16_t vlan_id, int
> on)
> {
> struct iavf_adapter *adapter =
> IAVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private);
> struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(adapter);
> - struct rte_eth_conf *dev_conf = &dev->data->dev_conf;
> int err;
>
> if (adapter->closed)
> @@ -1380,7 +1405,8 @@ iavf_dev_vlan_filter_set(struct rte_eth_dev *dev,
> uint16_t vlan_id, int on)
> err = iavf_add_del_vlan_v2(adapter, vlan_id, on);
> if (err)
> return -EIO;
> - return 0;
> +
> + return iavf_disable_vlan_strip_ex(dev, on);
> }
>
> if (!(vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_VLAN))
> @@ -1390,23 +1416,7 @@ iavf_dev_vlan_filter_set(struct rte_eth_dev *dev,
> uint16_t vlan_id, int on)
> if (err)
> return -EIO;
>
> - /* For i40e kernel driver which only supports vlan(v1) VIRTCHNL OP,
> - * it will set strip on when setting filter on but dpdk side will
> not
> - * change strip flag. To be consistent with dpdk side, disable
> strip
> - * again.
> - *
> - * For i40e kernel driver which supports vlan v2, dpdk will invoke
> vlan v2
> - * related function, so it won't go through here.
> - */
> - if (adapter->hw.mac.type == IAVF_MAC_XL710 ||
> - adapter->hw.mac.type == IAVF_MAC_X722_VF) {
> - if (on && !(dev_conf->rxmode.offloads &
> RTE_ETH_RX_OFFLOAD_VLAN_STRIP)) {
> - err = iavf_disable_vlan_strip(adapter);
> - if (err)
> - return -EIO;
> - }
> - }
> - return 0;
> + return iavf_disable_vlan_strip_ex(dev, on);
> }
>
> static void
> --
> 2.34.1
>
> ---
> Diff of the applied patch vs upstream commit (please double-check if
> non-empty:
> ---
> --- - 2025-07-30 22:50:03.776876738 +0800
> +++ 0010-net-iavf-fix-VLAN-strip-setting-after-enabling-filte.patch
> 2025-07-30 22:50:03.000752668 +0800
> @@ -1 +1 @@
> -From 3bfad066f9b4764981c9ad90a750fa6f1afcf15a Mon Sep 17 00:00:00 2001
> +From f2c11a141c46c6a9d461493b70490940d8147680 Mon Sep 17 00:00:00 2001
> @@ -4,0 +5,3 @@
> +Cc: Xueming Li <xuemingl at nvidia.com>
> +
> +[ upstream commit 3bfad066f9b4764981c9ad90a750fa6f1afcf15a ]
> @@ -18,2 +21,2 @@
> - .mailmap | 1 +
> - drivers/net/intel/iavf/iavf_ethdev.c | 48 +++++++++++++++++-----------
> + .mailmap | 1 +
> + drivers/net/iavf/iavf_ethdev.c | 48 ++++++++++++++++++++--------------
> @@ -23 +26 @@
> -index c6d72058bb..1b238970fb 100644
> +index e17823a260..80c6f855dc 100644
> @@ -26 +29 @@
> -@@ -88,6 +88,7 @@ Amir Avivi <amir.avivi at intel.com>
> +@@ -84,6 +84,7 @@ Amir Avivi <amir.avivi at intel.com>
> @@ -34,5 +37,5 @@
> -diff --git a/drivers/net/intel/iavf/iavf_ethdev.c
> b/drivers/net/intel/iavf/iavf_ethdev.c
> -index 02649c19b2..c33fdd9069 100644
> ---- a/drivers/net/intel/iavf/iavf_ethdev.c
> -+++ b/drivers/net/intel/iavf/iavf_ethdev.c
> -@@ -1377,13 +1377,38 @@ iavf_dev_del_mac_addr(struct rte_eth_dev *dev,
> uint32_t index)
> +diff --git a/drivers/net/iavf/iavf_ethdev.c
> b/drivers/net/iavf/iavf_ethdev.c
> +index 4472fd2c2d..391ba2c812 100644
> +--- a/drivers/net/iavf/iavf_ethdev.c
> ++++ b/drivers/net/iavf/iavf_ethdev.c
> +@@ -1364,13 +1364,38 @@ iavf_dev_del_mac_addr(struct rte_eth_dev *dev,
> uint32_t index)
> @@ -78 +81 @@
> -@@ -1393,7 +1418,8 @@ iavf_dev_vlan_filter_set(struct rte_eth_dev *dev,
> uint16_t vlan_id, int on)
> +@@ -1380,7 +1405,8 @@ iavf_dev_vlan_filter_set(struct rte_eth_dev *dev,
> uint16_t vlan_id, int on)
> @@ -88 +91 @@
> -@@ -1403,23 +1429,7 @@ iavf_dev_vlan_filter_set(struct rte_eth_dev *dev,
> uint16_t vlan_id, int on)
> +@@ -1390,23 +1416,7 @@ iavf_dev_vlan_filter_set(struct rte_eth_dev *dev,
> uint16_t vlan_id, int on)
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mails.dpdk.org/archives/stable/attachments/20250730/5d2401fd/attachment.htm>
More information about the stable
mailing list