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 2430EA055D; Mon, 1 Mar 2021 10:53:54 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B300D4067B; Mon, 1 Mar 2021 10:53:53 +0100 (CET) Received: from new4-smtp.messagingengine.com (new4-smtp.messagingengine.com [66.111.4.230]) by mails.dpdk.org (Postfix) with ESMTP id 0B5BB4014E for ; Mon, 1 Mar 2021 10:53:52 +0100 (CET) Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailnew.nyi.internal (Postfix) with ESMTP id 2D3E0580249; Mon, 1 Mar 2021 04:53:51 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute2.internal (MEProxy); Mon, 01 Mar 2021 04:53:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=fm3; bh= 5oJSOgveeNPGQCfzOq07AR03tAf8KgnB86DRDbGzQCQ=; b=BhyiPEKc+omPFgVu kXiWv24UoOQJTRqzH1vnDO6CxVYZrMQw4jwOKNn7fXiXGvZPHrKg71gkPzTXaVG/ LmRfv70xeHCK2YAv8VC9NmnFekO3moBxRDE+9Q45oGz6RV4IG3BLZgqQgPuBSIx0 4WV8FsDg62Nc56XppMct0hFtmZUfW9qTveASDPkKCymMCrHpa9eqzqmdoCotAsZ7 WHuMIB6oCDWNJNtZde/fcUpXl2z/rekz5QXmSGKcjV5KyoEOEyx5NtqeD0pkO8bm GMVAgGlRIn/UTGfCtxNzRPBgm5pF+e435J4Y2CDHR0i7ZGDszsua0bmlj8v06+8W I5sSkg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=5oJSOgveeNPGQCfzOq07AR03tAf8KgnB86DRDbGzQ CQ=; b=uzj0Z4VW8n107bih4h4y+736WpFuv8XOxtlGAp/rQDi+PL6ceE5uhdkK5 B+ZisbOiJVEk02DbOAD8mNegy1jwoBBRK8QiEaDOuENVxbf0d1oSxoln4P6GP1Pz +FFzoYECduz5aNNmWCuwC0zNnJvS9QCjQa9iVMtKvuSE+muaSrQz4EcZBDIVR8Bl yDsh01k9M2P9wsmWYqleNSCVWNM8vJLxAqMKkb1T6L6iIE2mhMd0XlbU3su9yS0c v7HW714BD7223LtmMQJcvCTfyVfR1CWJGLV3oc6NXQNYl1Z1GLSGTKQ3UAMca4AQ dt4dJmig8yxsIPY/G579nT75Pd51Q== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrleekgddtjecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhmrghs ucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenucggtf frrghtthgvrhhnpeffvdffjeeuteelfeeileduudeugfetjeelveefkeejfeeigeehteff vdekfeegudenucffohhmrghinhepughpughkrdhorhhgnecukfhppeejjedrudefgedrvd dtfedrudekgeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhr ohhmpehthhhomhgrshesmhhonhhjrghlohhnrdhnvght X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 33F5624005E; Mon, 1 Mar 2021 04:53:48 -0500 (EST) From: Thomas Monjalon To: Bruce Richardson Cc: dev@dpdk.org, ncopa@alpinelinux.org, Anatoly Burakov , Stephen Hemminger , Long Li , Jay Zhou , Timothy McDaniel , Rasesh Mody , Shahed Shaikh , Andrew Boyer , Maxime Coquelin , Chenbo Xia , Xiao Wang Date: Mon, 01 Mar 2021 10:53:46 +0100 Message-ID: <3488412.QTiPZ3pNak@thomas> In-Reply-To: <20210301094102.GA1251@bricha3-MOBL.ger.corp.intel.com> References: <20190313170657.16688-1-ncopa@alpinelinux.org> <20210228125353.2436562-8-thomas@monjalon.net> <20210301094102.GA1251@bricha3-MOBL.ger.corp.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v6 07/17] drivers: replace page size definitions with function 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" 01/03/2021 10:41, Bruce Richardson: > On Sun, Feb 28, 2021 at 01:53:42PM +0100, Thomas Monjalon wrote: > > The page size is often retrieved from the macro PAGE_SIZE. > > If PAGE_SIZE is not defined, it is either using hard coded default, > > or getting the system value from the UNIX-only function sysconf(). > > > > Such definitions are replaced with the generic function > > rte_mem_page_size() defined for each supported OS. > > > > Removing PAGE_SIZE definitions will fix dlb drivers for musl libc, > > because #ifdef checks were missing, causing redefinition errors. > > > > Signed-off-by: Thomas Monjalon > > --- > Is the header file with the rte_mem_page_size() function missing from this > patch? No, the function exists since DPDK 20.08. > Also, rather than a function for this, would it not be better to keep it as > a macro as RTE_PAGE_SIZE, to keep it more in line with the macro people > expect to have available? No because the size is not always known at compilation time. See the implementation: https://git.dpdk.org/dpdk/commit/?id=c4b89ecb64eae