aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/dpdk/device
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2021-09-16 20:50:12 -0700
committerFlorin Coras <fcoras@cisco.com>2021-09-16 20:50:12 -0700
commit91db3538c923063f9ddc8e7bde8c8481372fe14a (patch)
tree169724961c339b5fd22bc72b64c5bbbe6fdc7721 /src/plugins/dpdk/device
parent895def45c82ea5d901987bc3049c8d1cc1c1da66 (diff)
dpdk: fix checksum offload
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I89fb738903ee74ffcb7c77a041391f0388df6991
Diffstat (limited to 'src/plugins/dpdk/device')
-rw-r--r--src/plugins/dpdk/device/device.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/plugins/dpdk/device/device.c b/src/plugins/dpdk/device/device.c
index 095036fcb5c..b29c80cd79d 100644
--- a/src/plugins/dpdk/device/device.c
+++ b/src/plugins/dpdk/device/device.c
@@ -259,8 +259,7 @@ dpdk_buffer_tx_offload (dpdk_device_t * xd, vlib_buffer_t * b,
}
else
{
- mb->l2_len =
- vnet_buffer (b)->l3_hdr_offset - vnet_buffer (b)->l2_hdr_offset;
+ mb->l2_len = vnet_buffer (b)->l3_hdr_offset - b->current_data;
mb->l3_len =
vnet_buffer (b)->l4_hdr_offset - vnet_buffer (b)->l3_hdr_offset;
mb->outer_l2_len = 0;