aboutsummaryrefslogtreecommitdiffstats
path: root/vnet/vnet/devices/dpdk/dpdk.h
diff options
context:
space:
mode:
authorJohn Lo <loj@cisco.com>2016-07-07 13:54:44 -0400
committerDamjan Marion <dmarion.lists@gmail.com>2016-07-08 09:38:56 +0000
commitce3e971bab3a67b5d484294f5cfd3d270c76bc38 (patch)
tree4eb8bc94dcc88259b45b699c71802f2265ad1962 /vnet/vnet/devices/dpdk/dpdk.h
parent618ab08c4f0bccc4ceca6a8b18ea797fbe9fd5a7 (diff)
Allow DPDK per interface startup config to enable/disable VLAN stripping
The init of VIC/ENIC ports enable VLAN stripping of received packets by default, which is different to all other devices. The VLAN stripping of ENIC ports can be disabled by adding the per device DPDK config as "vlan-strip-offload off" such as: dpdk {... dev 0000:0c:00.0 {vlan-strip-offload off} ...} The per device config "vlan-strip-offload on" can be used for enabling VLAN stripping for other devices which support this function but is disabled by default. Change-Id: I9c81904a87c26868a07900b03677aeeb57f72372 Signed-off-by: John Lo <loj@cisco.com>
Diffstat (limited to 'vnet/vnet/devices/dpdk/dpdk.h')
-rw-r--r--vnet/vnet/devices/dpdk/dpdk.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/vnet/vnet/devices/dpdk/dpdk.h b/vnet/vnet/devices/dpdk/dpdk.h
index dee4625b82f..05f74b849f5 100644
--- a/vnet/vnet/devices/dpdk/dpdk.h
+++ b/vnet/vnet/devices/dpdk/dpdk.h
@@ -294,6 +294,11 @@ typedef struct dpdk_efd_t {
typedef struct {
vlib_pci_addr_t pci_addr;
u8 is_blacklisted;
+ u8 vlan_strip_offload;
+#define DPDK_DEVICE_VLAN_STRIP_DEFAULT 0
+#define DPDK_DEVICE_VLAN_STRIP_OFF 1
+#define DPDK_DEVICE_VLAN_STRIP_ON 2
+
#define _(x) uword x;
foreach_dpdk_device_config_item
#undef _