summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--dpdk/Makefile1
-rw-r--r--vnet/vnet/devices/dpdk/dpdk.h20
-rw-r--r--vnet/vnet/devices/dpdk/init.c8
3 files changed, 29 insertions, 0 deletions
diff --git a/dpdk/Makefile b/dpdk/Makefile
index d73ddb62e2e..975042521f0 100644
--- a/dpdk/Makefile
+++ b/dpdk/Makefile
@@ -30,6 +30,7 @@ DPDK_TARBALL := dpdk-$(DPDK_VERSION).tar.xz
DPDK_TAR_URL := $(DPDK_BASE_URL)/$(DPDK_TARBALL)
DPDK_16.04_TARBALL_MD5_CKSUM := d1f82e7d7589b3b2f623c155442b8306
DPDK_16.07_TARBALL_MD5_CKSUM := 690a2bb570103e58d12f9806e8bf21be
+DPDK_16.11-rc1_TARBALL_MD5_CKSUM := 69a13a554160622a0fdb87f52539073f
DPDK_SOURCE := $(B)/dpdk-$(DPDK_VERSION)
ifneq (,$(findstring clang,$(CC)))
diff --git a/vnet/vnet/devices/dpdk/dpdk.h b/vnet/vnet/devices/dpdk/dpdk.h
index c2ea579a6fe..e34d4b97bdd 100644
--- a/vnet/vnet/devices/dpdk/dpdk.h
+++ b/vnet/vnet/devices/dpdk/dpdk.h
@@ -65,6 +65,25 @@ extern vnet_device_class_t dpdk_device_class;
extern vlib_node_registration_t dpdk_input_node;
extern vlib_node_registration_t handoff_dispatch_node;
+#if RTE_VERSION >= RTE_VERSION_NUM(16, 11, 0, 0)
+#define foreach_dpdk_pmd \
+ _ ("net_thunderx", THUNDERX) \
+ _ ("net_e1000_em", E1000EM) \
+ _ ("net_e1000_igb", IGB) \
+ _ ("net_e1000_igb_vf", IGBVF) \
+ _ ("net_ixgbe", IXGBE) \
+ _ ("net_ixgbe_vf", IXGBEVF) \
+ _ ("net_i40e", I40E) \
+ _ ("net_i40e_vf", I40EVF) \
+ _ ("net_virtio", VIRTIO) \
+ _ ("net_enic", ENIC) \
+ _ ("net_vmxnet3", VMXNET3) \
+ _ ("net_af_packet", AF_PACKET) \
+ _ ("net_bonding", BOND) \
+ _ ("net_fm10k", FM10K) \
+ _ ("net_cxgbe", CXGBE) \
+ _ ("net_dpaa2", DPAA2)
+#else
#define foreach_dpdk_pmd \
_ ("rte_nicvf_pmd", THUNDERX) \
_ ("rte_em_pmd", E1000EM) \
@@ -82,6 +101,7 @@ extern vlib_node_registration_t handoff_dispatch_node;
_ ("rte_pmd_fm10k", FM10K) \
_ ("rte_cxgbe_pmd", CXGBE) \
_ ("rte_dpaa2_dpni", DPAA2)
+#endif
typedef enum
{
diff --git a/vnet/vnet/devices/dpdk/init.c b/vnet/vnet/devices/dpdk/init.c
index 7045e454048..c57fcde3543 100644
--- a/vnet/vnet/devices/dpdk/init.c
+++ b/vnet/vnet/devices/dpdk/init.c
@@ -431,7 +431,11 @@ dpdk_lib_init (dpdk_main_t * dm)
/* workaround for drivers not setting driver_name */
if ((!dev_info.driver_name) && (dev_info.pci_dev))
+#if RTE_VERSION < RTE_VERSION_NUM(16, 11, 0, 0)
dev_info.driver_name = dev_info.pci_dev->driver->name;
+#else
+ dev_info.driver_name = dev_info.pci_dev->driver->driver.name;
+#endif
ASSERT (dev_info.driver_name);
if (!xd->pmd)
@@ -1554,7 +1558,11 @@ dpdk_process (vlib_main_t * vm, vlib_node_runtime_t * rt, vlib_frame_t * f)
struct rte_eth_dev_info dev_info;
rte_eth_dev_info_get (i, &dev_info);
if (!dev_info.driver_name)
+#if RTE_VERSION < RTE_VERSION_NUM(16, 11, 0, 0)
dev_info.driver_name = dev_info.pci_dev->driver->name;
+#else
+ dev_info.driver_name = dev_info.pci_dev->driver->driver.name;
+#endif
ASSERT (dev_info.driver_name);
if (strncmp (dev_info.driver_name, "rte_bond_pmd", 12) == 0)
{