From: Ajit Khaparde Date: Mon, 26 Oct 2020 03:56:14 +0000 (-0700) Subject: net/bnxt: fix resetting mbuf data offset X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=3cefa72935fde04824fdfbee9c435c08278ab3c2;p=dpdk.git net/bnxt: fix resetting mbuf data offset Reset mbuf->data_off before handing the Rx packet to the application. We were not doing this in the TPA path. It can cause applications using this field for post processing to work incorrectly. Fixes: 0958d8b6435d ("net/bnxt: support LRO") Cc: stable@dpdk.org Signed-off-by: Ajit Khaparde Reviewed-by: Lance Richardson --- diff --git a/drivers/net/bnxt/bnxt_rxr.c b/drivers/net/bnxt/bnxt_rxr.c index 2645ed61f4..4d0ab604f3 100644 --- a/drivers/net/bnxt/bnxt_rxr.c +++ b/drivers/net/bnxt/bnxt_rxr.c @@ -150,6 +150,7 @@ static void bnxt_tpa_start(struct bnxt_rx_queue *rxq, tpa_info->mbuf = mbuf; tpa_info->len = rte_le_to_cpu_32(tpa_start->len); + mbuf->data_off = RTE_PKTMBUF_HEADROOM; mbuf->nb_segs = 1; mbuf->next = NULL; mbuf->pkt_len = rte_le_to_cpu_32(tpa_start->len);