From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id CC9191B82C for ; Mon, 29 Jan 2018 16:09:24 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 29 Jan 2018 07:09:23 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.46,431,1511856000"; d="scan'208";a="23336340" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by FMSMGA003.fm.intel.com with ESMTP; 29 Jan 2018 07:09:23 -0800 Received: from fmsmsx155.amr.corp.intel.com (10.18.116.71) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 29 Jan 2018 07:09:23 -0800 Received: from BGSMSX107.gar.corp.intel.com (10.223.4.191) by FMSMSX155.amr.corp.intel.com (10.18.116.71) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 29 Jan 2018 07:09:23 -0800 Received: from bgsmsx101.gar.corp.intel.com ([169.254.1.25]) by BGSMSX107.gar.corp.intel.com ([169.254.9.47]) with mapi id 14.03.0319.002; Mon, 29 Jan 2018 20:39:20 +0530 From: "Varghese, Vipin" To: "Van Haaren, Harry" , "dev@dpdk.org" CC: "thomas@monjalon.net" Thread-Topic: [PATCH v3 3/4] app/pdump: call eal cleanup before exit Thread-Index: AQHTmPnmTDbxiRtGUkGnpcoa7HT1JqOK9DGA Date: Mon, 29 Jan 2018 15:09:20 +0000 Message-ID: <4C9E0AB70F954A408CC4ADDBF0F8FA7D4D191D80@BGSMSX101.gar.corp.intel.com> References: <1517222751-110376-1-git-send-email-harry.van.haaren@intel.com> <1517227695-146913-1-git-send-email-harry.van.haaren@intel.com> <1517227695-146913-3-git-send-email-harry.van.haaren@intel.com> In-Reply-To: <1517227695-146913-3-git-send-email-harry.van.haaren@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ctpclassification: CTP_NT x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNWNmMDJhMzAtZDRmYS00MTcyLThiNWYtODI5NWJhYTY5ZDk4IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjIuNS4xOCIsIlRydXN0ZWRMYWJlbEhhc2giOiJ1SmZHNzE4bnoxYlRFejRqdEdzSW0wVVwvcUpMemFyYVwvc2VZVGlWZWRvamFHd2xYSnlyRDRRVmw4S0pPaDlCZWwifQ== dlp-product: dlpe-windows dlp-version: 11.0.0.116 dlp-reaction: no-action x-originating-ip: [10.223.10.10] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v3 3/4] app/pdump: call eal cleanup before exit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Jan 2018 15:09:25 -0000 > -----Original Message----- > From: Van Haaren, Harry > Sent: Monday, January 29, 2018 5:38 PM > To: dev@dpdk.org > Cc: Van Haaren, Harry ; thomas@monjalon.net; > Varghese, Vipin > Subject: [PATCH v3 3/4] app/pdump: call eal cleanup before exit >=20 > This patch adds a call to the newly introduced cleanup() function just be= fore > quitting the pdump app. >=20 > Adding this function call before quitting from a secondary processes is > important, as otherwise it will leak hugepage memory. For a secondary pro= cess > that is run multiple times, this could cause hugepage memory to become > depleted and stop a secondary process from starting. >=20 > Signed-off-by: Harry van Haaren >=20 > --- >=20 > v3: > - Rework to new cleanup() function name (Thomas) >=20 > Cc: thomas@monjalon.net > Cc: vipin.varghese@intel.com > --- > app/pdump/main.c | 5 +++++ > 1 file changed, 5 insertions(+) >=20 > diff --git a/app/pdump/main.c b/app/pdump/main.c index 0f70c75..50772cb > 100644 > --- a/app/pdump/main.c > +++ b/app/pdump/main.c > @@ -882,5 +882,10 @@ main(int argc, char **argv) > /* dump debug stats */ > print_pdump_stats(); >=20 > + ret =3D rte_eal_cleanup(); > + if (ret) > + printf("Error from rte_eal_cleanup(), %d\n", ret); > + > + > return 0; > } > -- > 2.7.4 Tested with static and dynamic library on Linux Acked-by: Vipin Varghese