From 84799b868da958c3a0921a7580ee2104113580c4 Mon Sep 17 00:00:00 2001 From: Yunjian Wang Date: Sat, 5 Sep 2020 17:36:53 +0800 Subject: [PATCH] net/bnxt: fix freeing mbuf We should use rte_pktmbuf_free() instead of rte_free() to free the mbuf. Fixes: 6dc83230b43b ("net/bnxt: support port representor data path") Cc: stable@dpdk.org Signed-off-by: Yunjian Wang Reviewed-by: Ajit Khaparde --- drivers/net/bnxt/bnxt_reps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/bnxt/bnxt_reps.c b/drivers/net/bnxt/bnxt_reps.c index 6695896dd2..2f2af0d44d 100644 --- a/drivers/net/bnxt/bnxt_reps.c +++ b/drivers/net/bnxt/bnxt_reps.c @@ -61,7 +61,7 @@ bnxt_vfr_recv(uint16_t port_id, uint16_t queue_id, struct rte_mbuf *mbuf) } else { vfr_bp->rx_drop_bytes[que] += mbuf->pkt_len; vfr_bp->rx_drop_pkts[que]++; - rte_free(mbuf); /* Representor Rx ring full, drop pkt */ + rte_pktmbuf_free(mbuf); /* Representor Rx ring full, drop pkt */ } return 0; -- 2.20.1