diff options
author | Dave Barach <dave@barachs.net> | 2017-06-29 09:30:15 -0400 |
---|---|---|
committer | Florin Coras <florin.coras@gmail.com> | 2017-07-18 17:05:01 +0000 |
commit | 2c0a4f407f565d8dd33ff3a9fada346860d30ad2 (patch) | |
tree | feef8e57bc4f7b434715bd04c9be218ce215bdd0 /src/plugins/dpdk/device/init.c | |
parent | 758137a7b70806dc9ec7a28fbe1bc01bc7df2586 (diff) |
TCP/UDP checksum offload API
Change-Id: I2cb6ce4e29813f6602b14e6e61713fb381fbcef8
Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'src/plugins/dpdk/device/init.c')
-rwxr-xr-x | src/plugins/dpdk/device/init.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/plugins/dpdk/device/init.c b/src/plugins/dpdk/device/init.c index 7ca3d358403..8a7080352e7 100755 --- a/src/plugins/dpdk/device/init.c +++ b/src/plugins/dpdk/device/init.c @@ -351,6 +351,11 @@ dpdk_lib_init (dpdk_main_t * dm) case VNET_DPDK_PMD_IGB: case VNET_DPDK_PMD_IXGBE: case VNET_DPDK_PMD_I40E: + xd->port_type = port_type_from_speed_capa (&dev_info); + xd->flags |= DPDK_DEVICE_FLAG_TX_OFFLOAD | + DPDK_DEVICE_FLAG_INTEL_PHDR_CKSUM; + + break; case VNET_DPDK_PMD_CXGBE: case VNET_DPDK_PMD_MLX4: case VNET_DPDK_PMD_MLX5: @@ -575,6 +580,9 @@ dpdk_lib_init (dpdk_main_t * dm) hi = vnet_get_hw_interface (dm->vnet_main, xd->hw_if_index); + if (xd->flags & DPDK_DEVICE_FLAG_TX_OFFLOAD) + hi->flags |= VNET_HW_INTERFACE_FLAG_SUPPORTS_TX_L4_CKSUM_OFFLOAD; + dpdk_device_setup (xd); if (vec_len (xd->errors)) |