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 0A85E5F25 for ; Tue, 30 Apr 2019 04:33:26 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 29 Apr 2019 19:33:26 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,412,1549958400"; d="scan'208";a="138585481" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by orsmga008.jf.intel.com with ESMTP; 29 Apr 2019 19:33:25 -0700 Received: from fmsmsx157.amr.corp.intel.com (10.18.116.73) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.408.0; Mon, 29 Apr 2019 19:33:25 -0700 Received: from bgsmsx153.gar.corp.intel.com (10.224.23.4) by FMSMSX157.amr.corp.intel.com (10.18.116.73) with Microsoft SMTP Server (TLS) id 14.3.408.0; Mon, 29 Apr 2019 19:33:25 -0700 Received: from bgsmsx101.gar.corp.intel.com ([169.254.1.225]) by BGSMSX153.gar.corp.intel.com ([169.254.2.183]) with mapi id 14.03.0415.000; Tue, 30 Apr 2019 08:03:22 +0530 From: "Varghese, Vipin" To: Suanming.Mou , "dev@dpdk.org" CC: "Burakov, Anatoly" Thread-Topic: [PATCH v4] app/pdump: add pudmp exits with primary support. Thread-Index: AQHU/vU4Oglrpk2vD0KrNBbxZXOcjKZT+vgQ Date: Tue, 30 Apr 2019 02:33:21 +0000 Message-ID: <4C9E0AB70F954A408CC4ADDBF0F8FA7D4D33FA5F@BGSMSX101.gar.corp.intel.com> References: <1556428025-49290-1-git-send-email-mousuanming@huawei.com> <1556595548-53745-1-git-send-email-mousuanming@huawei.com> In-Reply-To: <1556595548-53745-1-git-send-email-mousuanming@huawei.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: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNDc3YmI2NGQtZTk5Ny00MmNmLTgxOTgtYWRlZjU5NzVkODU2IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiTkM3dGxNT2lpeE1ZTlY2ZVRsMEZPRmppV0dHaXJ0TU5mMXNDZjFhY3VNb29zZEdjVGdqekZMT1ZyNTMzWDBBZSJ9 dlp-product: dlpe-windows dlp-version: 11.0.600.7 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 v4] app/pdump: add pudmp exits with primary support. 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: Tue, 30 Apr 2019 02:33:27 -0000 Thanks for the patch work with rte_eal_alaram. But I am not able to find=20 1. the documentation update. 2. cover letter. 3. for signal SIGINT, set for ` rte_eal_alarm_cancel`.=20 Can you share a new patch as v5 with these changes? Thanks Vipin Varghese > -----Original Message----- > From: Suanming.Mou > Sent: Tuesday, April 30, 2019 9:09 AM > To: dev@dpdk.org > Cc: Varghese, Vipin ; Burakov, Anatoly > > Subject: [PATCH v4] app/pdump: add pudmp exits with primary support. >=20 > When primary app exits, the residual running pdump will stop the primary = app to > restart. Add pdump exits with primary support. >=20 > Suggested-by: Varghese, Vipin > Suggested-by: Burakov, Anatoly > Signed-off-by: Suanming.Mou > --- > app/pdump/main.c | 16 ++++++++++++++++ > 1 file changed, 16 insertions(+) >=20 > diff --git a/app/pdump/main.c b/app/pdump/main.c index 3d20854..c3413da > 100644 > --- a/app/pdump/main.c > +++ b/app/pdump/main.c > @@ -26,6 +26,7 @@ > #include > #include > #include > +#include >=20 > #define CMD_LINE_OPT_PDUMP "pdump" > #define CMD_LINE_OPT_PDUMP_NUM 256 > @@ -65,6 +66,7 @@ > #define SIZE 256 > #define BURST_SIZE 32 > #define NUM_VDEVS 2 > +#define MONITOR_INTERVAL (500 * 1000) >=20 > /* true if x is a power of 2 */ > #define POWEROF2(x) ((((x)-1) & (x)) =3D=3D 0) @@ -864,12 +866,26 @@ str= uct > parse_val { > return 0; > } >=20 > +static void monitor_primary(void *arg __rte_unused) { > + if (quit_signal) > + return; > + > + if (rte_eal_primary_proc_alive(NULL)) > + rte_eal_alarm_set(MONITOR_INTERVAL, monitor_primary, > NULL); > + else > + quit_signal =3D 1; > +} > + > static inline void > dump_packets(void) > { > int i; > uint32_t lcore_id =3D 0; >=20 > + /* Once primary exits, so will pdump. */ > + rte_eal_alarm_set(MONITOR_INTERVAL, monitor_primary, NULL); > + > if (!multiple_core_capture) { > printf(" core (%u), capture for (%d) tuples\n", > rte_lcore_id(), num_tuples); > -- > 1.8.3.4 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 7877FA0679 for ; Tue, 30 Apr 2019 04:33:29 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 0B2285F44; Tue, 30 Apr 2019 04:33:28 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 0A85E5F25 for ; Tue, 30 Apr 2019 04:33:26 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 29 Apr 2019 19:33:26 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,412,1549958400"; d="scan'208";a="138585481" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by orsmga008.jf.intel.com with ESMTP; 29 Apr 2019 19:33:25 -0700 Received: from fmsmsx157.amr.corp.intel.com (10.18.116.73) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.408.0; Mon, 29 Apr 2019 19:33:25 -0700 Received: from bgsmsx153.gar.corp.intel.com (10.224.23.4) by FMSMSX157.amr.corp.intel.com (10.18.116.73) with Microsoft SMTP Server (TLS) id 14.3.408.0; Mon, 29 Apr 2019 19:33:25 -0700 Received: from bgsmsx101.gar.corp.intel.com ([169.254.1.225]) by BGSMSX153.gar.corp.intel.com ([169.254.2.183]) with mapi id 14.03.0415.000; Tue, 30 Apr 2019 08:03:22 +0530 From: "Varghese, Vipin" To: Suanming.Mou , "dev@dpdk.org" CC: "Burakov, Anatoly" Thread-Topic: [PATCH v4] app/pdump: add pudmp exits with primary support. Thread-Index: AQHU/vU4Oglrpk2vD0KrNBbxZXOcjKZT+vgQ Date: Tue, 30 Apr 2019 02:33:21 +0000 Message-ID: <4C9E0AB70F954A408CC4ADDBF0F8FA7D4D33FA5F@BGSMSX101.gar.corp.intel.com> References: <1556428025-49290-1-git-send-email-mousuanming@huawei.com> <1556595548-53745-1-git-send-email-mousuanming@huawei.com> In-Reply-To: <1556595548-53745-1-git-send-email-mousuanming@huawei.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: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNDc3YmI2NGQtZTk5Ny00MmNmLTgxOTgtYWRlZjU5NzVkODU2IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiTkM3dGxNT2lpeE1ZTlY2ZVRsMEZPRmppV0dHaXJ0TU5mMXNDZjFhY3VNb29zZEdjVGdqekZMT1ZyNTMzWDBBZSJ9 dlp-product: dlpe-windows dlp-version: 11.0.600.7 dlp-reaction: no-action x-originating-ip: [10.223.10.10] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v4] app/pdump: add pudmp exits with primary support. 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Message-ID: <20190430023321.z0okjfqklov1xSWfL7sUrhQ0O2a7mAOWflFEGAJeC7E@z> Thanks for the patch work with rte_eal_alaram. But I am not able to find=20 1. the documentation update. 2. cover letter. 3. for signal SIGINT, set for ` rte_eal_alarm_cancel`.=20 Can you share a new patch as v5 with these changes? Thanks Vipin Varghese > -----Original Message----- > From: Suanming.Mou > Sent: Tuesday, April 30, 2019 9:09 AM > To: dev@dpdk.org > Cc: Varghese, Vipin ; Burakov, Anatoly > > Subject: [PATCH v4] app/pdump: add pudmp exits with primary support. >=20 > When primary app exits, the residual running pdump will stop the primary = app to > restart. Add pdump exits with primary support. >=20 > Suggested-by: Varghese, Vipin > Suggested-by: Burakov, Anatoly > Signed-off-by: Suanming.Mou > --- > app/pdump/main.c | 16 ++++++++++++++++ > 1 file changed, 16 insertions(+) >=20 > diff --git a/app/pdump/main.c b/app/pdump/main.c index 3d20854..c3413da > 100644 > --- a/app/pdump/main.c > +++ b/app/pdump/main.c > @@ -26,6 +26,7 @@ > #include > #include > #include > +#include >=20 > #define CMD_LINE_OPT_PDUMP "pdump" > #define CMD_LINE_OPT_PDUMP_NUM 256 > @@ -65,6 +66,7 @@ > #define SIZE 256 > #define BURST_SIZE 32 > #define NUM_VDEVS 2 > +#define MONITOR_INTERVAL (500 * 1000) >=20 > /* true if x is a power of 2 */ > #define POWEROF2(x) ((((x)-1) & (x)) =3D=3D 0) @@ -864,12 +866,26 @@ str= uct > parse_val { > return 0; > } >=20 > +static void monitor_primary(void *arg __rte_unused) { > + if (quit_signal) > + return; > + > + if (rte_eal_primary_proc_alive(NULL)) > + rte_eal_alarm_set(MONITOR_INTERVAL, monitor_primary, > NULL); > + else > + quit_signal =3D 1; > +} > + > static inline void > dump_packets(void) > { > int i; > uint32_t lcore_id =3D 0; >=20 > + /* Once primary exits, so will pdump. */ > + rte_eal_alarm_set(MONITOR_INTERVAL, monitor_primary, NULL); > + > if (!multiple_core_capture) { > printf(" core (%u), capture for (%d) tuples\n", > rte_lcore_id(), num_tuples); > -- > 1.8.3.4