From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id D5A11A054F; Mon, 1 Mar 2021 16:34:06 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6866222A247; Mon, 1 Mar 2021 16:34:06 +0100 (CET) Received: from APC01-PU1-obe.outbound.protection.outlook.com (mail-oln040092254036.outbound.protection.outlook.com [40.92.254.36]) by mails.dpdk.org (Postfix) with ESMTP id 8E35740041 for ; Mon, 1 Mar 2021 16:34:05 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JLZleP8oz6/A6TMRny7Bit9t/XAnvN8uaPmdzHCWXH9Y0RTfX+37rlLUa4BiBhau80tQXdAy9jztJmMSOV8ma+vn4pseNo3njbFfq+Vr2Up78II1FPY+XasTaEJLEquvZYP5E7s/OvPUV9PEKgzJ2g91Mr9EjT1RS3uYCRyQyaSWk/H7qlYsPpq4KaqpLApTXkx0L7Yi7GvwKhatKmaV1v5OPgoxwCkPPBOOTpRb0VYCKZIR0bI7E2SHUoaI9dzOApmnR9eEmquRWvwPBFIQS9lWApOyN2+UeGaalwpOb8cPykNP3pwhh7h8RTNjqHSYTDduBHGbcnFum9nuclG2nw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=K0aG3Tikw+FP52d5cVR/1j5uR1HJpk6LE9NdzPXH9o8=; b=i9b+QHEtI1+Va1Yd6qRLy33zAS2TRuygFKwbe44BdBVSXRsrSP/RJejiIQVrI6PDR1YZ9ijGJyr8bba9DaKVMrmg12mSf3QWx0E6rQiaoqpNK+hjEGua1hViQPV2pdA5wP/IsgdgPla619GN0xSFALOb3F1M5GZ17x/uLR2RpPC6ToPv/r4fJMLQxk9+JabQsR04bOgtaBtR71bmkYkUKinPVj6vG8f/+MXVXLo5cGEYv9/sTB0Em0d9qheCDVjQlEcBNRgsGltbyrqDahKNJOxEXPOQO4XcO/Me5vBskRmDBkZwg3OxYr6Hr0eho+Gytwp2ZlIHoFyOuSktZjLejA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=K0aG3Tikw+FP52d5cVR/1j5uR1HJpk6LE9NdzPXH9o8=; b=gTF1Tk5YCFWl05rrePiugt6rePlPhfuOoKlMwS+vmL6XmEl+6UuTsGD570UDKQdrhl3eCVYA6fDTNrOy76PREnbHMZju91vsSP113P0j/31AQ1sjtRWRCkR5k6nvMUplhjzh9YCzjAVyu7OHvr8qAOMkg3ThycfPq2hSHp4BNo/Xx/EV+fhkzdAuW5KnSByyDapftP1X6krYf0ZgNJkuNALChVDPIvGy2kd4mu0WlBfGO0EJUPJVzi+LKF4/IRZ1OrugNJdyccxxOxZT03ydjIZ1Un3V19yHGiErHD54D67FyJYlxU5I3Hn3lqvWJN2WM1frVbikbYHH3Nn3iVU0qA== Received: from PU1APC01FT055.eop-APC01.prod.protection.outlook.com (2a01:111:e400:7ebe::45) by PU1APC01HT234.eop-APC01.prod.protection.outlook.com (2a01:111:e400:7ebe::468) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3890.19; Mon, 1 Mar 2021 15:34:03 +0000 Received: from ME3P282MB1668.AUSP282.PROD.OUTLOOK.COM (2a01:111:e400:7ebe::49) by PU1APC01FT055.mail.protection.outlook.com (2a01:111:e400:7ebe::362) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3890.19 via Frontend Transport; Mon, 1 Mar 2021 15:34:03 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:7754294F1B566560A9C57B20A9B2EFD71D08E24B427B612CADFB907E9DD0D94A; UpperCasedChecksum:22D4B0FB327D77EB5B1022D247E31ED4FF95B53A38F0971A50F684BE7C3AE866; SizeAsReceived:7297; Count:45 Received: from ME3P282MB1668.AUSP282.PROD.OUTLOOK.COM ([fe80::cde5:5660:e27b:a333]) by ME3P282MB1668.AUSP282.PROD.OUTLOOK.COM ([fe80::cde5:5660:e27b:a333%8]) with mapi id 15.20.3890.028; Mon, 1 Mar 2021 15:34:03 +0000 From: ZhangTengfei To: Ferruh Yigit Cc: dev@dpdk.org, ZhangTengfei Date: Mon, 1 Mar 2021 23:30:21 +0800 Message-ID: X-Mailer: git-send-email 2.26.2 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-TMN: [nB2lCs9keX6QgpIY3HM7eIbktnNq8MtU] X-ClientProxiedBy: HK2PR02CA0204.apcprd02.prod.outlook.com (2603:1096:201:20::16) To ME3P282MB1668.AUSP282.PROD.OUTLOOK.COM (2603:10c6:220:a5::11) X-Microsoft-Original-Message-ID: <20210301153021.4791-1-zypscode@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (222.95.177.75) by HK2PR02CA0204.apcprd02.prod.outlook.com (2603:1096:201:20::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3890.20 via Frontend Transport; Mon, 1 Mar 2021 15:34:01 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 45 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: ac5e85a3-a727-4af7-5d5e-08d8dcc77112 X-MS-Exchange-SLBlob-MailProps: CaK+F7me6Cnb1KK2VlXWwFUhMwpsMomckVxvthFBunUksibw7QfL6xHMox1KitBtoNxTTDA0iELeTuoZDwmRAHgp3jwwyvxla4h3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ra5ZvGE5G14dKE3kvtClAGWCJ3FsZMFypBeJdkCRYT6bvZPwIuemiFJg== X-MS-Exchange-AntiSpam-MessageData: VDCC916nekt3Cac4lamU1+nCONvyMW5wwq4nitHfidZtF0VVAiPSqL8BiXTbsO+EkFESJp6ELQUOYurhQ7LcjdKKdDjsMQjDSzCg5aiBXs9OPQocGCSn7nEQ757sJ439gBXH+pczfQs6VZ+MEPjd2w== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: ac5e85a3-a727-4af7-5d5e-08d8dcc77112 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Mar 2021 15:34:02.9792 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: PU1APC01FT055.eop-APC01.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: PU1APC01HT234 Subject: [dpdk-dev] [PATCH v2] driver/net/pcap fix: fd leak bug X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" pcap fd was opend when vdev probed, but not closed when vdev removed. This bug appears in dpdk-pdump Signed-off-by: ZhangTengfei --- 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