DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH v2] driver/net/pcap fix: fd leak bug
@ 2021-03-01 15:30 ZhangTengfei
  2021-03-02 11:00 ` Ferruh Yigit
  0 siblings, 1 reply; 2+ messages in thread
From: ZhangTengfei @ 2021-03-01 15:30 UTC (permalink / raw)
  To: Ferruh Yigit; +Cc: dev, ZhangTengfei

pcap fd was opend when vdev probed,
but not closed when vdev removed.
This bug appears in dpdk-pdump

Signed-off-by: ZhangTengfei <zypscode@outlook.com>
---
 drivers/net/pcap/rte_eth_pcap.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/pcap/rte_eth_pcap.c b/drivers/net/pcap/rte_eth_pcap.c
index 90f5d75ea..396de29de 100644
--- a/drivers/net/pcap/rte_eth_pcap.c
+++ b/drivers/net/pcap/rte_eth_pcap.c
@@ -755,6 +755,8 @@ eth_dev_close(struct rte_eth_dev *dev)
 	PMD_LOG(INFO, "Closing pcap ethdev on NUMA socket %d",
 			rte_socket_id());
 
+	eth_dev_stop(dev);
+
 	rte_free(dev->process_private);
 
 	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
-- 
2.26.2


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-03-02 11:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-01 15:30 [dpdk-dev] [PATCH v2] driver/net/pcap fix: fd leak bug ZhangTengfei
2021-03-02 11:00 ` Ferruh Yigit

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).