patch 'net/cpfl: fix VF ID calculation for vCPF' has been queued to stable release 25.11.5
Kevin Traynor
ktraynor at redhat.com
Thu Dec 3 14:00:31 CET 2026
Hi,
FYI, your patch has been queued to stable release 25.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 12/08/26. 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/d5cdebd52aace5d51409591b77f4e51d4ef776d3
Thanks.
Kevin
---
>From d5cdebd52aace5d51409591b77f4e51d4ef776d3 Mon Sep 17 00:00:00 2001
From: Atul Patel <atul.patel at intel.com>
Date: Fri, 28 Aug 2026 02:52:16 +0530
Subject: [PATCH] net/cpfl: fix VF ID calculation for vCPF
[ upstream commit 8e254d0df6692463b0cd60b15c441636fab65060 ]
The VF ID was incorrectly set to only the PCI function number,
which fails when VFs span multiple PCI devices (device IDs > 0).
Calculate the VF ID as (device_id * 8) + function to correctly
map VFs across devices.
Fixes: f1ab44fb0ebf ("net/cpfl: add vCPF port info")
Signed-off-by: Praveen Shetty <praveen.shetty at intel.com>
Signed-off-by: Atul Patel <atul.patel at intel.com>
Signed-off-by: Dhananjay Shukla <dhananjay.shukla at intel.com>
Acked-by: Bruce Richardson <bruce.richardson at intel.com>
---
drivers/net/intel/cpfl/cpfl_ethdev.c | 3 ++-
drivers/net/intel/cpfl/cpfl_ethdev.h | 10 ++++++++++
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/drivers/net/intel/cpfl/cpfl_ethdev.c b/drivers/net/intel/cpfl/cpfl_ethdev.c
index a770a35a2c..8c7a7fd16c 100644
--- a/drivers/net/intel/cpfl/cpfl_ethdev.c
+++ b/drivers/net/intel/cpfl/cpfl_ethdev.c
@@ -2840,5 +2840,6 @@ cpfl_dev_vport_init(struct rte_eth_dev *dev, void *init_params)
vi.func_type = VCPF_CPCHNL2_FTYPE_LAN_VF;
vi.pf_id = CPFL_HOST0_CPF_ID;
- vi.vf_id = pci_dev->addr.function;
+ vi.vf_id = VCPF_VF_ID_FROM_PCI(pci_dev->addr.devid,
+ pci_dev->addr.function);
v_id.vport_id = cpfl_vport->base.vport_info.info.vport_id;
diff --git a/drivers/net/intel/cpfl/cpfl_ethdev.h b/drivers/net/intel/cpfl/cpfl_ethdev.h
index e05a0901d5..fce54b4e50 100644
--- a/drivers/net/intel/cpfl/cpfl_ethdev.h
+++ b/drivers/net/intel/cpfl/cpfl_ethdev.h
@@ -104,4 +104,14 @@
(((pf_id) & 0x1) << 12) + ((vf_id) & 0xfff))
+/* Max VFs per PCI device (functions 0-7) */
+#define VCPF_VFS_PER_PCI_DEV 8
+
+/* Calculate VF ID from PCI device and function IDs.
+ * VFs span multiple PCI devices, e.g.:
+ * device 0: VF 0-7, device 1: VF 8-15, etc.
+ */
+#define VCPF_VF_ID_FROM_PCI(device_id, function) \
+ (((device_id) * VCPF_VFS_PER_PCI_DEV) + (function))
+
struct cpfl_vport_param {
struct cpfl_adapter_ext *adapter;
--
2.56.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2026-12-03 12:52:42.268037501 +0000
+++ 0105-net-cpfl-fix-VF-ID-calculation-for-vCPF.patch 2026-12-03 12:52:39.097896323 +0000
@@ -1 +1 @@
-From 8e254d0df6692463b0cd60b15c441636fab65060 Mon Sep 17 00:00:00 2001
+From d5cdebd52aace5d51409591b77f4e51d4ef776d3 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 8e254d0df6692463b0cd60b15c441636fab65060 ]
+
@@ -12 +13,0 @@
-Cc: stable at dpdk.org
@@ -24 +25 @@
-index 20ed819498..5a890f8131 100644
+index a770a35a2c..8c7a7fd16c 100644
@@ -27 +28 @@
-@@ -2953,5 +2953,6 @@ cpfl_dev_vport_init(struct rte_eth_dev *dev, void *init_params)
+@@ -2840,5 +2840,6 @@ cpfl_dev_vport_init(struct rte_eth_dev *dev, void *init_params)
@@ -36 +37 @@
-index 070030ffd8..49a0979f2c 100644
+index e05a0901d5..fce54b4e50 100644
@@ -39 +40 @@
-@@ -105,4 +105,14 @@
+@@ -104,4 +104,14 @@
More information about the stable
mailing list