From: Tianli Lai <laitianli@tom.com>
To: dev@dpdk.org
Subject: [PATCH] app/pdump: free mempool at cleanup resources
Date: Thu, 24 Feb 2022 20:52:17 +0800 [thread overview]
Message-ID: <1645707137-53479-1-git-send-email-laitianli@tom.com> (raw)
the mempool should be free when cleanup resources.
Signed-off-by: Tianli Lai <laitianli@tom.com>
---
app/pdump/main.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/app/pdump/main.c b/app/pdump/main.c
index 04a38e8..9c77fc6 100644
--- a/app/pdump/main.c
+++ b/app/pdump/main.c
@@ -507,6 +507,10 @@ struct parse_val {
/* free the rings */
rte_ring_free(pt->rx_ring);
rte_ring_free(pt->tx_ring);
+ if (pt->mp) {
+ rte_mempool_free(pt->mp);
+ pt->mp = NULL;
+ }
}
}
--
1.8.3.1
next reply other threads:[~2022-02-24 12:52 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-24 12:52 Tianli Lai [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-02-25 1:00 Tianli Lai
2022-02-25 2:40 ` Stephen Hemminger
2022-03-07 23:21 ` Thomas Monjalon
2022-02-24 12:14 Tianli Lai
2022-02-24 16:01 ` Stephen Hemminger
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:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1645707137-53479-1-git-send-email-laitianli@tom.com \
--to=laitianli@tom.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* 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).