From 6b3e017e5d25f15da73f7700f7f2ac553ef1a2e9 Mon Sep 17 00:00:00 2001 From: Christian Ehrhardt Date: Thu, 8 Dec 2016 14:07:29 +0100 Subject: Imported Upstream version 16.11 Change-Id: I1944c65ddc88a9ad70f8c0eb6731552b84fbcb77 Signed-off-by: Christian Ehrhardt --- app/test-pmd/txonly.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'app/test-pmd/txonly.c') diff --git a/app/test-pmd/txonly.c b/app/test-pmd/txonly.c index 11fd681d..8513a062 100644 --- a/app/test-pmd/txonly.c +++ b/app/test-pmd/txonly.c @@ -56,7 +56,6 @@ #include #include #include -#include #include #include #include @@ -223,6 +222,14 @@ pkt_burst_transmit(struct fwd_stream *fs) return; break; } + + /* + * Using raw alloc is good to improve performance, + * but some consumers may use the headroom and so + * decrement data_off. We need to make sure it is + * reset to default value. + */ + rte_pktmbuf_reset_headroom(pkt); pkt->data_len = tx_pkt_seg_lengths[0]; pkt_seg = pkt; if (tx_pkt_split == TX_PKT_SPLIT_RND) -- cgit 1.2.3-korg