From: "Shetty, Praveen" <praveen.shetty@intel.com>
To: bruce.richardson@intel.com, aman.deep.singh@intel.com
Cc: dev@dpdk.org, Praveen Shetty <praveen.shetty@intel.com>
Subject: [PATCH 1/4] net/intel: add vCPF PMD support
Date: Mon, 22 Sep 2025 11:48:16 +0200 [thread overview]
Message-ID: <20250922094819.1350709-2-praveen.shetty@intel.com> (raw)
In-Reply-To: <20250922094819.1350709-1-praveen.shetty@intel.com>
From: Praveen Shetty <praveen.shetty@intel.com>
This patch adds the registration support for a new vCPF PMD.
vCPF PMD is responsible for enabling control and data path
functionality for the CPF VF devices.
Signed-off-by: Praveen Shetty <praveen.shetty@intel.com>
---
drivers/net/intel/cpfl/cpfl_ethdev.c | 17 +++++++++++++++++
drivers/net/intel/cpfl/cpfl_ethdev.h | 1 +
drivers/net/intel/idpf/idpf_common_device.c | 4 ++--
drivers/net/intel/idpf/idpf_common_device.h | 1 +
4 files changed, 21 insertions(+), 2 deletions(-)
diff --git a/drivers/net/intel/cpfl/cpfl_ethdev.c b/drivers/net/intel/cpfl/cpfl_ethdev.c
index 6d7b23ad7a..d6227c99b5 100644
--- a/drivers/net/intel/cpfl/cpfl_ethdev.c
+++ b/drivers/net/intel/cpfl/cpfl_ethdev.c
@@ -1854,6 +1854,7 @@ cpfl_handle_virtchnl_msg(struct cpfl_adapter_ext *adapter)
switch (mbx_op) {
case idpf_mbq_opc_send_msg_to_peer_pf:
+ case idpf_mbq_opc_send_msg_to_peer_drv:
if (vc_op == VIRTCHNL2_OP_EVENT) {
cpfl_handle_vchnl_event_msg(adapter, adapter->base.mbx_resp,
ctlq_msg.data_len);
@@ -2610,6 +2611,11 @@ static const struct rte_pci_id pci_id_cpfl_map[] = {
{ .vendor_id = 0, /* sentinel */ },
};
+static const struct rte_pci_id pci_id_vcpf_map[] = {
+ { RTE_PCI_DEVICE(IDPF_INTEL_VENDOR_ID, IXD_DEV_ID_VCPF) },
+ { .vendor_id = 0, /* sentinel */ },
+};
+
static struct cpfl_adapter_ext *
cpfl_find_adapter_ext(struct rte_pci_device *pci_dev)
{
@@ -2866,6 +2872,14 @@ static struct rte_pci_driver rte_cpfl_pmd = {
.remove = cpfl_pci_remove,
};
+static struct rte_pci_driver rte_vcpf_pmd = {
+ .id_table = pci_id_vcpf_map,
+ .drv_flags = RTE_PCI_DRV_NEED_MAPPING |
+ RTE_PCI_DRV_PROBE_AGAIN,
+ .probe = cpfl_pci_probe,
+ .remove = cpfl_pci_remove,
+};
+
/**
* Driver initialization routine.
* Invoked once at EAL init time.
@@ -2874,6 +2888,9 @@ static struct rte_pci_driver rte_cpfl_pmd = {
RTE_PMD_REGISTER_PCI(net_cpfl, rte_cpfl_pmd);
RTE_PMD_REGISTER_PCI_TABLE(net_cpfl, pci_id_cpfl_map);
RTE_PMD_REGISTER_KMOD_DEP(net_cpfl, "* igb_uio | vfio-pci");
+RTE_PMD_REGISTER_PCI(net_vcpf, rte_vcpf_pmd);
+RTE_PMD_REGISTER_PCI_TABLE(net_vcpf, pci_id_vcpf_map);
+RTE_PMD_REGISTER_KMOD_DEP(net_vcpf, "* igb_uio | vfio-pci");
RTE_PMD_REGISTER_PARAM_STRING(net_cpfl,
CPFL_TX_SINGLE_Q "=<0|1> "
CPFL_RX_SINGLE_Q "=<0|1> "
diff --git a/drivers/net/intel/cpfl/cpfl_ethdev.h b/drivers/net/intel/cpfl/cpfl_ethdev.h
index d4e1176ab1..2cfcdd6206 100644
--- a/drivers/net/intel/cpfl/cpfl_ethdev.h
+++ b/drivers/net/intel/cpfl/cpfl_ethdev.h
@@ -60,6 +60,7 @@
/* Device IDs */
#define IDPF_DEV_ID_CPF 0x1453
+#define IXD_DEV_ID_VCPF 0x1203
#define VIRTCHNL2_QUEUE_GROUP_P2P 0x100
#define CPFL_HOST_ID_NUM 2
diff --git a/drivers/net/intel/idpf/idpf_common_device.c b/drivers/net/intel/idpf/idpf_common_device.c
index ff1fbcd2b4..8c637a2fb6 100644
--- a/drivers/net/intel/idpf/idpf_common_device.c
+++ b/drivers/net/intel/idpf/idpf_common_device.c
@@ -130,7 +130,7 @@ idpf_init_mbx(struct idpf_hw *hw)
struct idpf_ctlq_info *ctlq;
int ret = 0;
- if (hw->device_id == IDPF_DEV_ID_SRIOV)
+ if (hw->device_id == IDPF_DEV_ID_SRIOV || hw->device_id == IXD_DEV_ID_VCPF)
ret = idpf_ctlq_init(hw, IDPF_CTLQ_NUM, vf_ctlq_info);
else
ret = idpf_ctlq_init(hw, IDPF_CTLQ_NUM, pf_ctlq_info);
@@ -389,7 +389,7 @@ idpf_adapter_init(struct idpf_adapter *adapter)
struct idpf_hw *hw = &adapter->hw;
int ret;
- if (hw->device_id == IDPF_DEV_ID_SRIOV) {
+ if (hw->device_id == IDPF_DEV_ID_SRIOV || hw->device_id == IXD_DEV_ID_VCPF) {
ret = idpf_check_vf_reset_done(hw);
} else {
idpf_reset_pf(hw);
diff --git a/drivers/net/intel/idpf/idpf_common_device.h b/drivers/net/intel/idpf/idpf_common_device.h
index 5f3e4a4fcf..d536ce7e15 100644
--- a/drivers/net/intel/idpf/idpf_common_device.h
+++ b/drivers/net/intel/idpf/idpf_common_device.h
@@ -11,6 +11,7 @@
#include "idpf_common_logs.h"
#define IDPF_DEV_ID_SRIOV 0x145C
+#define IXD_DEV_ID_VCPF 0x1203
#define IDPF_RSS_KEY_LEN 52
--
2.37.3
next prev parent reply other threads:[~2025-09-22 6:19 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-22 9:48 [PATCH 0/4] add vcpf pmd support Shetty, Praveen
2025-09-22 9:48 ` Shetty, Praveen [this message]
2025-09-22 14:10 ` [PATCH v2 " Shetty, Praveen
2025-09-22 14:10 ` [PATCH v2 1/4] net/intel: add vCPF PMD support Shetty, Praveen
2025-09-23 12:54 ` [PATCH v3 0/4] add vcpf pmd support Shetty, Praveen
2025-09-23 12:54 ` [PATCH v3 1/4] net/intel: add vCPF PMD support Shetty, Praveen
2025-09-23 12:54 ` [PATCH v3 2/4] net/idpf: add splitq jumbo packet handling Shetty, Praveen
2025-09-23 12:54 ` [PATCH v3 3/4] net/intel: add config queue support to vCPF Shetty, Praveen
2025-09-23 12:54 ` [PATCH v3 4/4] net/cpfl: add cpchnl get vport info support Shetty, Praveen
2025-09-26 8:11 ` Shetty, Praveen
2025-09-22 14:10 ` [PATCH v2 2/4] net/idpf: add splitq jumbo packet handling Shetty, Praveen
2025-09-22 14:10 ` [PATCH v2 3/4] net/intel: add config queue support to vCPF Shetty, Praveen
2025-09-22 14:10 ` [PATCH v2 4/4] net/cpfl: add cpchnl get vport info support Shetty, Praveen
2025-09-22 9:48 ` [PATCH 2/4] net/idpf: add splitq jumbo packet handling Shetty, Praveen
2025-09-22 9:48 ` [PATCH 3/4] net/intel: add config queue support to vCPF Shetty, Praveen
2025-09-22 9:48 ` [PATCH 4/4] net/cpfl: add cpchnl get vport info support Shetty, Praveen
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=20250922094819.1350709-2-praveen.shetty@intel.com \
--to=praveen.shetty@intel.com \
--cc=aman.deep.singh@intel.com \
--cc=bruce.richardson@intel.com \
--cc=dev@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).