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 8A39341CE5; Mon, 20 Feb 2023 11:16:49 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 13FAC4300C; Mon, 20 Feb 2023 11:16:49 +0100 (CET) Received: from wout4-smtp.messagingengine.com (wout4-smtp.messagingengine.com [64.147.123.20]) by mails.dpdk.org (Postfix) with ESMTP id D622840395 for ; Mon, 20 Feb 2023 11:16:47 +0100 (CET) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.west.internal (Postfix) with ESMTP id 216263200D58; Mon, 20 Feb 2023 05:16:44 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute5.internal (MEProxy); Mon, 20 Feb 2023 05:16:44 -0500 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=fm1; t=1676888203; x= 1676974603; bh=KkTV1ndtaUyqr+DRKMZI5u+Mq9cxqKuCv1VKkI4CPao=; b=e S/EVxsbaD+YbctQQkkQGQFtRPeDUVC2D70l6Yqwrwso7V7ld58i2+73qRM2G4oTn rdo1Nyc+FQe2ZdIZpX3SPKyqFBKqPkTRZ+e0EgtoCtM/9+vO5UwYfDLXObEsNbNf xeVksF6sFcDmt369ppzAX/BfAtCGMStvd2SaiYabhUhKq1yUPVQOLZNHmrzHjI90 wdLcDgjo7uORUdjaP/2llehOZfUyla3algUMhs3p7R90T2EEJEDNnWlKiCSgUQQ8 bWszWwZ/4eGYSjske0aSo3RAr0tIwfE82kNteFG6bk9kSwo1rV/el7oy8kg3SEkd PkMaUFoPC07xicVdTccbw== 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=fm1; t=1676888203; x= 1676974603; bh=KkTV1ndtaUyqr+DRKMZI5u+Mq9cxqKuCv1VKkI4CPao=; b=N ewqEjTvl+Wh/k5WrZfZse4PPmEr3UfUyzDUySSf7eDbHuB1jrpwQXxHTQ8FV+8nG /R3F2aNnfR/uAlMLbtyw6yHQb1h56qbkuHAy7vvHke6pI/Hor6Ocvp8u5GfTjIC/ loar/XPOP9E1Jn6sUL7lnJ8kZ2cTlkhE4HbtlP+ACccqk+gTDkjX8jTSvXAWkX96 tf7N8y9FmUFe0OM9VFFOW1DlZGKqaXB9lYJlyC76qAiaUzhtm7Uu9YUZHFAKoT93 QH0jJPq761OE5NxeJXNJct/UcNdGttxEaiQJqreWX7CSt61pK6sM2OlKA8/MJZhl u+yAOsgMz+/0hn5Lp91Fg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrudejhedgudduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvvefufffkjghfggfgtgesthhqredttddtudenucfhrhhomhepvfhhohhm rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc ggtffrrghtthgvrhhnpeetvdeggffftdfhkeffudfhveeugeeuleeutdeljeejkeelleff uddtkeehieekgeenucffohhmrghinhepsghoohhtlhhinhdrtghomhenucevlhhushhtvg hrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhomhgrshesmhhonhhj rghlohhnrdhnvght X-ME-Proxy: Feedback-ID: i47234305:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 20 Feb 2023 05:16:41 -0500 (EST) From: Thomas Monjalon To: bruce.richardson@intel.com, Chengwen Feng , Ruifeng Wang , Morten =?ISO-8859-1?Q?Br=F8rup?= Cc: dev@dpdk.org, nd , ferruh.yigit@amd.com, Dongdong Liu , Yisen Zhuang Subject: Re: [PATCH] net/hns3: support disable IOVA as PA mode Date: Mon, 20 Feb 2023 11:16:40 +0100 Message-ID: <1759668.5KxKD5qtyk@thomas> In-Reply-To: <98CBD80474FA8B44BF855DF32C47DC35D87754@smartserver.smartshare.dk> References: <20230214071141.50155-1-fengchengwen@huawei.com> <7487991.nlapOpYt14@thomas> <98CBD80474FA8B44BF855DF32C47DC35D87754@smartserver.smartshare.dk> 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 20/02/2023 10:43, Morten Br=F8rup: > > From: Thomas Monjalon [mailto:thomas@monjalon.net] > > Sent: Monday, 20 February 2023 08.45 > >=20 > > 16/02/2023 09:36, Ruifeng Wang: > > > From: Chengwen Feng > > > > Subject: [PATCH] net/hns3: support disable IOVA as PA mode > >=20 > > Could we change the title to "support IOVA as VA" ? >=20 > The underlying problem is the meson configuration option name for this fe= ature [1]: >=20 > option('enable_iova_as_pa', type: 'boolean', value: true, description: > 'Support for IOVA as physical address. Disabling removes the buf_i= ova field of mbuf.') >=20 > [1]: https://elixir.bootlin.com/dpdk/v22.11.1/source/meson_options.txt#L43 >=20 > Formally, the patch provides the ability to set a boolean configuration v= alue ("enable_iova_as_pa") to false, and thus the patch title is correct. >=20 > Nonetheless, I agree that the title suggested by Thomas is an improvement. >=20 >=20 > Going back to the root cause, I think the configuration option should be = an enum instead of a boolean, e.g. "iova_mode" with values "iova_pa" and "i= ova_va". We can enable both and have it decided at runtime. So I think the boolean i= s OK. > It's somewhat similar to CPU endian macros. We have macros defining both = Big Endian and Little Endian, not just one macro defining Big Endian or not. >=20 > @Bruce, would it be hard for you to change the IOVA configuration option = from a boolean to a two-value enum? >=20 > Or - also considering the resulting #define's - would it be too difficult= to keep a sufficient level of backwards/API compatibility?