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 0479DA0547; Mon, 27 Sep 2021 09:56:10 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BA265410DF; Mon, 27 Sep 2021 09:56:09 +0200 (CEST) Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) by mails.dpdk.org (Postfix) with ESMTP id 677AE406A3 for ; Mon, 27 Sep 2021 09:56:06 +0200 (CEST) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 1D9F85C00E8; Mon, 27 Sep 2021 03:56:06 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute3.internal (MEProxy); Mon, 27 Sep 2021 03:56:06 -0400 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=fm2; bh= PaRs0O1UtozOxa6jRQM7rzCmZAl+mWuY2c4iFhJv5ew=; b=TYz3Xr5G+7PjwCvN +uRYQJxg2TR0St9rQOSQTG3SB4Q/XaB3j3xNr68Nuqw+66421VEIbyrwsXxNS3Ej inEEBJcWSPVglzlot5ItLxEmxh6O9Xz6y5TXZJjYd6Lh4/tQxNzWfYk8Bmdvqg77 8x//Fo/Tx9PccOiZZ/CfAr400DV7wg+HlJZQsmOSHNQ2mAGiEav5tD+t4FEE3RkY FdTsGEXzrgMQpY6txT8hi+KGIvpycSnwVpxGeY3cGitWApzG/WYfhH5LsH7XeIp/ /zFxnzryVph75HdfOVktwGJlizSXDgmiMvi+Ue0LG/ZYjUR0ZmkmLLGYypREjkgG zgUSVA== 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=fm3; bh=PaRs0O1UtozOxa6jRQM7rzCmZAl+mWuY2c4iFhJv5 ew=; b=Ihxn+5PD4URmegsvz9e8zgOrxLqzreh72xh5I+YjQgBZznuaJ/2sHTDTl WKUtppmtVcDCXxQYVQOawu0WO5QmoL+f44yFYwKg+8X1l0w1HiHIIL+rvhwh1wJA K4FWPt5iB0pAYWmfFKHa1zHXNxMsYDTJDb3K/FoacLMdldRfnhEiGAztzdoFsyAy QYk8Zky9jiMb8odUZIWrZ6CnJilNzdMiWMjR7G9t24xNRvoEsgxRwrAqhML37G0G hWLkF+DfuiOcbCoKMhtqGc6gc3bTMUxAY3XSoqW0yyiQu3tFm95AW9sM/AkvEEE8 tyB+d/gKK4rQrgzJscwGIccuHiU3A== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvtddrudejjedguddvfecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefhvffufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhm rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc ggtffrrghtthgvrhhnpedugefgvdefudfftdefgeelgffhueekgfffhfeujedtteeutdej ueeiiedvffegheenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfh hrohhmpehthhhomhgrshesmhhonhhjrghlohhnrdhnvght X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 27 Sep 2021 03:56:05 -0400 (EDT) From: Thomas Monjalon To: "Wang, Jie1X" Cc: "dev@dpdk.org" , "Yigit, Ferruh" , "andrew.rybchenko@oktetlabs.ru" , "Li, Xiaoyun" , "Yang, SteveX" Date: Mon, 27 Sep 2021 09:56:04 +0200 Message-ID: <1981336.HCRrZqnFLi@thomas> In-Reply-To: References: <20210827081740.365037-1-jie1x.wang@intel.com> <2103588.zk1eQJicq0@thomas> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v9 1/3] ethdev: add an API to get device configuration info 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" 27/09/2021 09:21, Wang, Jie1X: > From: Thomas Monjalon > > 26/09/2021 11:20, Jie Wang: > > > This patch adds a new API "rte_eth_dev_conf_info_get()" to help users > > > get device configuration info. > > [...] > > > + * Retrieve the configuration of an Ethernet device. > > > + * > > > + * @param port_id > > > + * The port identifier of the Ethernet device. > > > + * @param dev_conf_info > > > + * A pointer to a structure of type *rte_eth_conf* to be filled with > > > + * the configuration of the Ethernet device. > > > + * And the memory of the structure should be allocated by the caller. > > > + * @return > > > + * - (0) if successful. > > > + * - (-ENODEV) if *port_id* invalid. > > > + * - (-EINVAL) if bad parameter. > > > + */ > > > +__rte_experimental > > > +int rte_eth_dev_conf_info_get(uint16_t port_id, > > > + struct rte_eth_conf *dev_conf_info); > > > > It does not make sense to me. > > rte_eth_conf is passed by the app to rte_eth_dev_configure. > > Why the app would need to get the same info back? > > > > > > In rte_eth_dev_configure, dev->data->dev_conf copies the info from port->dev_conf, and then the driver updates it. It doesn't same as port->dev_conf. > We need to get the updated device configuration. OK I see. Please update the commit log to explain this.