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 92B12A00C3; Mon, 19 Sep 2022 13:20:27 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 70ACB40E0F; Mon, 19 Sep 2022 13:20:27 +0200 (CEST) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by mails.dpdk.org (Postfix) with ESMTP id 4228240141 for ; Mon, 19 Sep 2022 13:20:26 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1663586426; x=1695122426; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=qRl3KU8WGjvzEWm043eLDq0NQb1UfMCEpnUk7LkbnDk=; b=anuH2I95UplO6FstDd9099fGi6YRI+HtwsDMI37Gk6ujcx7PUgShUrf/ ZWzA3C/laz6fhIVEM6/yrLWa9dT/Mzn6KuhARqY3CuxcwA4cYB7pf59p1 MgqvtFlPA3mwVl0Hx1BSnfkf1FuSlcfmuhTDqwxshspV4XvGU0sTaKi53 dnZ12adYDkj3BXBmj3akn+mm89km7rNEyeGSWnmCYkn03hAVXJEDY/Mdj d4tMKni+AYfuRashffIYgFQvXKZF1BvQyJPXDNwljsngOI/CNa3/vGU4t 19HnKY9vf4/Q/KNQV6WfkVuOPRCiG2Rgm2E6ujHmBB7ARMiiHBqQGgUpI A==; X-IronPort-AV: E=McAfee;i="6500,9779,10474"; a="279103712" X-IronPort-AV: E=Sophos;i="5.93,327,1654585200"; d="scan'208";a="279103712" Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Sep 2022 04:20:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.93,327,1654585200"; d="scan'208";a="618452863" Received: from fmsmsx601.amr.corp.intel.com ([10.18.126.81]) by orsmga002.jf.intel.com with ESMTP; 19 Sep 2022 04:20:24 -0700 Received: from fmsmsx608.amr.corp.intel.com (10.18.126.88) by fmsmsx601.amr.corp.intel.com (10.18.126.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Mon, 19 Sep 2022 04:20:24 -0700 Received: from fmsedg601.ED.cps.intel.com (10.1.192.135) by fmsmsx608.amr.corp.intel.com (10.18.126.88) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31 via Frontend Transport; Mon, 19 Sep 2022 04:20:24 -0700 Received: from NAM04-MW2-obe.outbound.protection.outlook.com (104.47.73.174) by edgegateway.intel.com (192.55.55.70) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2375.31; Mon, 19 Sep 2022 04:20:06 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=S2ZSOzPQ0VGjFmLih9tjJRsokhgmZ1n78OCpkQhUr6CHoCZh4bejeUaCw9Zu8MHY8E+Wgn8nJu2xy3aF2AVYG00zruj3DfBSt3nMrAdHQ2bYzQCxPoAk5PakDJPD2SRXhgxWWWOKZDCPZ4SVBzM5ULEVSpxorBfh/RIJl+0X010YruDoDm4uvWXCy5Q0AUiQFMb0CCRgy2/F45eL8d1ggb6JcvaVd1wOtVfMuzBy4I0Oo32Fy2PjYm+7b4NhivgWYA3B1yuYU+cL3NgdgtrEt0sjD4t7pYSnDU+wuuS9VelMnmU5AApZ46urPD5oac3fmyWBWGYGVhTmqt+p9FU+Dw== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=vWloFq+h2KrGBTsxsrfaBllVvQCcrvzohrSC/6mAHuA=; b=neKRxgIb/kghcDxJanmgVlmOg/3UeoRCpK824wvWVxoBIhZEybybQUkTwsSEJ1LisB6gctfq/QkguYr/uIS4FfIEVpdzWV0ieRKMH/MEqEFR4EMLRKdqOTOPjmSgIvJsXDdJAPmyDYQL3yiLSetl7jF830/VcuXyVvD72k9KqtlfEwU5/kWLseivynFydcDPQK/LApU/i2VPLQqeGBxNkJTit9zBQb7XJ4J4DKBAvWp9Pw2TxAwQG+aSyKgTeo9GMVPyLyATfYK44Dfq2H3JbsFItoG+eqLkS8CujXaPZwZ+mBVe4H5Vs0UsG/ctmBOskQO5aFLGzIEA7XzLtp9q9Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from DM6PR11MB3737.namprd11.prod.outlook.com (2603:10b6:5:144::28) by IA0PR11MB7258.namprd11.prod.outlook.com (2603:10b6:208:43d::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5632.21; Mon, 19 Sep 2022 11:19:59 +0000 Received: from DM6PR11MB3737.namprd11.prod.outlook.com ([fe80::2d92:7e15:6dd9:69f]) by DM6PR11MB3737.namprd11.prod.outlook.com ([fe80::2d92:7e15:6dd9:69f%6]) with mapi id 15.20.5632.021; Mon, 19 Sep 2022 11:19:59 +0000 From: "Kaur, Arshdeep" To: Stephen Hemminger , Ben Magistro CC: "dev@dpdk.org" Subject: RE: [RFT] dumpcap: add file-prefix option Thread-Topic: [RFT] dumpcap: add file-prefix option Thread-Index: AQHYxtplRdC30afRDUi3/7aVSZuaU63hu5eggABM64CAAC2WAIAEaNcg Date: Mon, 19 Sep 2022 11:19:59 +0000 Message-ID: References: <20220912124309.233363-1-arshdeep.kaur@intel.com> <20220912190330.73159-1-stephen@networkplumber.org> <20220916083508.62e44c3a@hermes.local> In-Reply-To: <20220916083508.62e44c3a@hermes.local> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.6.500.17 dlp-reaction: no-action authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: DM6PR11MB3737:EE_|IA0PR11MB7258:EE_ x-ms-office365-filtering-correlation-id: eea0e1f6-9c0b-4d80-32e3-08da9a30e3bc x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: eAR+zuddXUFWzHfcxN7/LMI6qOyTPUVTtNaXjNuZFpJG24KtWYC95+Or1DeUf2zgaMANJdEi2OpZ82mN2FK0DcD7ByZQVU5sdCFMouxEqaksxRQ4lAMIAg8MHJzfGmWkDWaiqpF25JBRNDHWJxkjcxPSwj33Kp2yx5T4RIOAb7teIN2fAz7Ns4/5agPoa0uU1dSHr4cnJxKC1pKMHtQ5+nT8JwrXtzFOvhYgXITYv+3mzdWsneIkvrDtWgm6gUrdWaa4fjsZHkzHcr/bavnV+97zMabHyqz1vBJA1khxrIJobdxpScFgS1HSvAzt3fZUGzZBav77qw6BN6BFzOxiQxB7ZZ80gBEDiIViF5ULDamSoSXejmZsiYs/WyQqiqbOIT2kgLOvz4PgeJvdc3Y04WPgoj2WDY+s6dZNKLLnedDsd5+pOqsGtewyggeF2XDmJbCB4mLLsTjeEQO6EH9K9RZZStVm6FWvUar6PDxI55uozwdc9iwU59vlWO1Jygfm7jNeB0XunUAGO0jwxrMuMbyDJF0g0RSbDqchfDPb/oIMZYIfqAepsCJsOQHF3UsEhi2FhA0XM+nBADPeiFumFUSFNFgK1P16muLxEDdVlD7/GS63Bz0iT8PC7hX9bE8i0nxDBkBc+7u4wT5j910/zWGPadJ88Y3bsyIGQb9E0wMzeQntkcUAYc8lMCCxvIKvjAHU08rrbd/lHQQHf2xYBzruFWNrIakPERFhZKQ8PmHUEUJuvgPG7KALi8avWmCoMOnAfx99WnnDrVgrTqmx8cmb18c4ej6FYEN2OZWHMoI= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR11MB3737.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230022)(136003)(346002)(396003)(376002)(39860400002)(366004)(451199015)(122000001)(66446008)(86362001)(33656002)(38100700002)(38070700005)(82960400001)(55016003)(2906002)(5660300002)(966005)(478600001)(66946007)(66556008)(4326008)(64756008)(66476007)(110136005)(8676002)(52536014)(8936002)(76116006)(316002)(186003)(83380400001)(41300700001)(71200400001)(7696005)(55236004)(53546011)(6506007)(26005)(9686003); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?eTq4LS1VRcx3bRi40ZuH812oeJS6jxfUwocIQsoJjNqK1KWJh8rpYPubX4LO?= =?us-ascii?Q?WsvnFnYmi3FVwJHLlNEz55HRwk/fahNwdp7Ys7RvDCSp84LybKgWFN1KnRhJ?= =?us-ascii?Q?NMDvyZTjUnsazObvUwutoLdiV9jgueQGHrxo/WiLj9Lq0/9L+j6mqfRqFxge?= =?us-ascii?Q?3J5T/3qeMhKnxjHESAnktGVZCMm20332rUReNmB4yFqCV1dzpYcKCbPI6+up?= =?us-ascii?Q?PPpwHjiQ1gZW8LjJaH9uphPYqq3+68PpBFYfEcRWtAybDQzm5Jbjt9I6EYoA?= =?us-ascii?Q?SXhDGrzPu0WjI9tHxLQZ7WeqT4dWsJzD685vc/ghyN5uL6tV5WdSbvirA5up?= =?us-ascii?Q?yaFmqQgnjmB+qY6Mdjn7E6mNsEgzrkX/01KIVsw+oA+On96/CG/EUCFDfRft?= =?us-ascii?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aQKnaZzBr5?= =?us-ascii?Q?iyFTU4o1Q/NRZzi4YiUNgZoUD52rIXhgAxh7FezOuxUWrHQFRci4PCrITzZU?= =?us-ascii?Q?6W6eMlf8sYrdmOmaMVDHDYIVbprT1z8FLOVW5tiuZnb91XiB4KOxTLVdzumF?= =?us-ascii?Q?u7kk+z8ux+FaryfMkAz+H5nk77r/JRhR2pHtuFm0e6GAB65JP8I8rihgoO05?= =?us-ascii?Q?e3uRBznS4QX+8ceGaEZgKDWjlgAZI0UI0pY5yHvc+F6+5ELiAN/yxWhTMNYL?= =?us-ascii?Q?4vYf1nOi4eg1hEw8wNP9kED09UT4GqPu2U8Ux7ys?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM6PR11MB3737.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: eea0e1f6-9c0b-4d80-32e3-08da9a30e3bc X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Sep 2022 11:19:59.5747 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: dJDFm26C032By0QxOAvhkWBgoYL0xmUNZL2uFuIjQCaNb0ASnNCBU2GqQSc9a12laadUQTdc8XLGkkgxft0L+w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: IA0PR11MB7258 X-OriginatorOrg: intel.com 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 > -----Original Message----- > From: Stephen Hemminger > Sent: Friday, September 16, 2022 9:05 PM > To: Ben Magistro > Cc: Kaur, Arshdeep ; dev@dpdk.org > Subject: Re: [RFT] dumpcap: add file-prefix option >=20 > On Fri, 16 Sep 2022 08:51:59 -0400 > Ben Magistro wrote: >=20 > > Kaur, > > > > I believe parse_opts() should be called before dpdk_init() now see > > https://patches.dpdk.org/project/dpdk/patch/20220125032545.7704-1- > konc > > ept1@gmail.com/ >=20 > Correct, in main branch parse_opts is before dpdk_init Hi Stephen and Ben. I have a doubt regarding this. According to me if dpdk_= init is called after parse_opts, then some caller functions (called from wi= thin parse_opts) are affected. Eg. 1) Parameter 'D' : { "list-interfaces", no_argument, NULL, 'D' },= does not give any output. 2) Parameter 'i' : { "interface", required_argument, NULL, 'i' }, do= es not behave properly.=20 I think the reason is that port list is available after eal init. Dumpcap(s= econdary process) will inherit the ports used by primary process. This implies that dpdk_init should be called before parse_opts. But then for multiprocess support, primary process is to be picked up by pr= oviding a file-prefix (Added in parse_opts). This implies that parse_opts should be called before dpdk_init. So according to me there was a deadlock situation here. Which I handled by = providing file-prefix input to the program before dpdk_init manually. And t= hen after dpdk_init, parse_opts should be called. Please let me know if I am going in the wrong direction. And how else can w= e solve this? NOTE: There is a bug in 'if' condition of select_interface function. Contro= l should enter the 'if' condition if we provide select interface as '*' but= instead it enters when they are unequal. So I have already submitted a pat= ch for that. And it is acknowledged. Change done is: - if (strcmp(arg, "*")) + if (!strcmp(arg, "*"))