DPDK patches and discussions
 help / color / mirror / Atom feed
From: wangyunjian <wangyunjian@huawei.com>
To: <dev@dpdk.org>
Cc: <ajit.khaparde@broadcom.com>, <somnath.kotur@broadcom.com>,
	<jerry.lilijun@huawei.com>, <xudingke@huawei.com>,
	Yunjian Wang <wangyunjian@huawei.com>, <stable@dpdk.org>
Subject: [dpdk-dev] [PATCH 2/2] net/bnxt: fix a wrong use of rte_free when freeing mbuf
Date: Sat, 5 Sep 2020 17:36:53 +0800	[thread overview]
Message-ID: <97580c5c0a88e8aa6982a7fcea6f34829891da07.1599292452.git.wangyunjian@huawei.com> (raw)
In-Reply-To: <cover.1599292452.git.wangyunjian@huawei.com>

From: Yunjian Wang <wangyunjian@huawei.com>

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 <wangyunjian@huawei.com>
 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 e924025cf..26bd0f626 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;
-		rte_free(mbuf); /* Representor Rx ring full, drop pkt */
+		rte_pktmbuf_free(mbuf); /* Representor Rx ring full, drop pkt */
 	return 0;

  parent reply	other threads:[~2020-09-05  9:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-05  9:36 [dpdk-dev] [PATCH 0/2] fixes for bnxt driver wangyunjian
2020-09-05  9:36 ` [dpdk-dev] [PATCH 1/2] net/bnxt: remove logically dead code wangyunjian
2020-09-05  9:36 ` wangyunjian [this message]
2020-09-11  3:22 ` [dpdk-dev] [PATCH 0/2] fixes for bnxt driver Ajit Khaparde

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=97580c5c0a88e8aa6982a7fcea6f34829891da07.1599292452.git.wangyunjian@huawei.com \
    --to=wangyunjian@huawei.com \
    --cc=ajit.khaparde@broadcom.com \
    --cc=dev@dpdk.org \
    --cc=jerry.lilijun@huawei.com \
    --cc=somnath.kotur@broadcom.com \
    --cc=stable@dpdk.org \
    --cc=xudingke@huawei.com \


* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).