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 2FC3BA00C5; Mon, 31 Oct 2022 16:03:32 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C38EE40223; Mon, 31 Oct 2022 16:03:31 +0100 (CET) Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by mails.dpdk.org (Postfix) with ESMTP id 1E08140151 for ; Mon, 31 Oct 2022 16:03:30 +0100 (CET) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id A25165C0199; Mon, 31 Oct 2022 11:03:29 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Mon, 31 Oct 2022 11:03:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:cc:content-transfer-encoding:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm3; t=1667228609; x= 1667315009; bh=sE34W4RExtoc9rLDKLndCNT3nBMNFb+I0JV2YDWOg4A=; b=V iJChGVqNVWZkoX4kWiCMTWDu9puSlIg/ZiPhNVVQyIfGBuBD6zSmevSfEpfoQxHR dMEYbcWn5uvCVWX0UeBw2AqifhaXC0wSpWvbJLwwNvaD88V/Otxlc18ajTf6lW8N xaEvxbcRbeC2HtcNHeSGrndsu75TabkwbBZQeNP5oNKX357NaF7U8ISvwVYA5JWf ECj1uRsdFZg8tNFBE1+ucMe37Z6mQixTySSa7lP7ozc74ljVMO1IgXHgK1JQOlOi OC3wkaab3lrt7wlPlaWMgjgFEw6Ywi78yv/bZgEQL53lX1J4abPa+eTB0kgvM/Fw 4LsrCntiVqsFRuqVg07Lw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1667228609; x= 1667315009; bh=sE34W4RExtoc9rLDKLndCNT3nBMNFb+I0JV2YDWOg4A=; b=s MzJci1Bj18Au+U6qKKEFP4O2WvYMmg0PYRM/AGO9JxD9pRXVLE0qF/dbTq5e/b9C 28UVR1irX9v3hnaRvzbg2/EF9g12XwNP3cxMhyqo1g70oRPkqCIQ5h36/F2cXiQZ ueX9Mgc1BfvDwDtcOubKB/Xs8MuRbeXTlNNKdbl9UWPE5PYyqz0OKg/QHmdf4MrM CZSmbZiYnEK0qpDc4+9RoyIIaz27vhIBjX7f+eauYRKcJS21s5V2aPCr1PeDqKGV yXWLhvwzVvur76Mjg/RUIltAywqIN2nfLHGyDmLiazQQwd9kXo4HY268satpUYpo 5xygApxqhix25Tdb3H8tg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvgedrudefgdejudcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvfevufffkfgjfhgggfgtsehtqhertddttddunecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecugg ftrfgrthhtvghrnhepfefhjeeluedvvedtuddtuedtvefhieejtefhffeujefhteduudev tdektdeikeffnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrh homhepthhhohhmrghssehmohhnjhgrlhhonhdrnhgvth X-ME-Proxy: Feedback-ID: i47234305:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 31 Oct 2022 11:03:27 -0400 (EDT) From: Thomas Monjalon To: Abdullah =?ISO-8859-1?Q?=D6mer_Yama=E7?= Cc: david.hunt@intel.com, dev@dpdk.org Subject: Re: [PATCH v3] examples/distributor: update dynamic configuration Date: Mon, 31 Oct 2022 16:03:25 +0100 Message-ID: <12443427.VsHLxoZxqI@thomas> In-Reply-To: <20220901140951.291068-1-omer.yamac@ceng.metu.edu.tr> References: <20220628195425.401077-1-omer.yamac@ceng.metu.edu.tr> <20220901140951.291068-1-omer.yamac@ceng.metu.edu.tr> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1" 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 Hello, Not a complete review, but few general comments to improve the patch below: 01/09/2022 16:09, Abdullah =D6mer Yama=E7: > In this patch, > * It is possible to switch the running mode of the distributor > using the command line argument. > * With "-c" parameter, you can run RX and Distributor > on the same core. > * Without "-c" parameter, you can run RX and Distributor > on the different core. > * Consecutive termination of the lcores fixed. > The termination order was wrong, and you couldn't terminate the > application while traffic was capturing. The current order is > RX -> Distributor -> TX -> Workers > * When "-c" parameter is active, the wasted distributor core is > also deactivated in the main function. Please could you make clear what was the issue, and what was changed in the commit message? > -#if 0 It's good to remove such thing. Dead code should not exist. > + /* > + * Swap the following two lines if you want the rx traffic > + * to go directly to tx, no distribution. > + */ In DPDK, it is preferred to use uppercase Rx and Tx. > + struct rte_ring *out_ring =3D p->rx_dist_ring; > + /* struct rte_ring *out_ring =3D p->dist_tx_ring; */ This line is dead code, please remove. > + if (!pd) It is preferred to not use boolean operator with pointer. Explicit comparison is encouraged: pd =3D=3D NULL > - rte_free(pd); > + if (pd) > + rte_free(pd); This check is useless because redundant with rte_free behaviour.