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 5CCCAA0350; Mon, 21 Feb 2022 16:49:55 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DE0414068C; Mon, 21 Feb 2022 16:49:54 +0100 (CET) Received: from new3-smtp.messagingengine.com (new3-smtp.messagingengine.com [66.111.4.229]) by mails.dpdk.org (Postfix) with ESMTP id 5FA684013F for ; Mon, 21 Feb 2022 16:49:54 +0100 (CET) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailnew.nyi.internal (Postfix) with ESMTP id A76BD5804C2; Mon, 21 Feb 2022 10:49:53 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Mon, 21 Feb 2022 10:49:53 -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=fm3; bh=T4iRfgYmILrQQi fR9uon4GsTtg+D+YqO5kYn9gtw1iM=; b=VOyiAK5PRRBf4XeinVyfwkyV5TVyDI HN5wRQaXDCYqW5UA99/MhglnvBSKVzntcyUmN3DaVNKnphtvYfgVEJ2hNyMKIKjL EK9iDis+nFwLURhk3WdAfyAAiUTJGX4CFdyp6xkprNXrd9YI3Rayf/NjKqnHo5mb UL5WyxcF7Gi60uoVaFckxlj+IWJSRZ6KcFeUEwRuBw32uf4uKU4cSHrzw+xepkRH FHelA4tUAQxTWrufp0SkYSddjR5/vP3IGRUbRbDxEIBT6st8nFnOMRfg882767Qk xd/51rMrizyXKZoQoZH7+MspVAfxbP5+JgF4seW7VFu+/iqE56nYOAXw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; 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:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=T4iRfgYmILrQQifR9uon4GsTtg+D+YqO5kYn9gtw1 iM=; b=HOd6iKq1h74YekFMKG4Mhf1l6l4uWXm1USMBrQETPnuvwHBK0nVpHktvm iv58f5K0lLgSvS7rWUPrug818kUtT9nDHuZvtwnlpnb6Jetl3mKXsk6q+Z+a6Qt6 xv2sCk6h95wp/MBumWuZ4VnNeZjjbm/8KepYkgYdMarnYXedorVy6khEumOGRIL1 p6H6g5UnxAbXr53OSu8BmfX3P9de8jUIuVQbF9gqULWn1J+e6UYTbU51fCzj4OJi r4Po8CYhkr5Zbpr7bMWn1XQzBz3uWib8Fc4gikr/yPf5962E1CdBD4/+r2Ip6Xpm hPHSEMNX+gw19s7IAf0HBVUYIbiBw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvvddrkeeigdejlecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhmrghs ucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenucggtf frrghtthgvrhhnpedugefgvdefudfftdefgeelgffhueekgfffhfeujedtteeutdejueei iedvffegheenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhroh hmpehthhhomhgrshesmhhonhhjrghlohhnrdhnvght X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 21 Feb 2022 10:49:52 -0500 (EST) From: Thomas Monjalon To: Ori Kam , Alexander Kozyrev , Andrew Rybchenko Cc: "dev@dpdk.org" , "ivan.malov@oktetlabs.ru" , "ferruh.yigit@intel.com" , "mohammad.abdul.awal@intel.com" , "qi.z.zhang@intel.com" , "jerinj@marvell.com" , "ajit.khaparde@broadcom.com" , "bruce.richardson@intel.com" Subject: Re: [PATCH v8 01/11] ethdev: introduce flow engine configuration Date: Mon, 21 Feb 2022 16:49:49 +0100 Message-ID: <1991723.o4kTbAZ4gJ@thomas> In-Reply-To: References: <20220219041144.2145380-1-akozyrev@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" 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 21/02/2022 15:53, Andrew Rybchenko: > On 2/21/22 15:53, Ori Kam wrote: > > From: Andrew Rybchenko > >>>> +/** > >>>> + * @warning > >>>> + * @b EXPERIMENTAL: this API may change without prior notice. > >>>> + * > >>>> + * Get information about flow engine resources. > >>>> + * > >>>> + * @param port_id > >>>> + * Port identifier of Ethernet device. > >>>> + * @param[out] port_info > >>>> + * A pointer to a structure of type *rte_flow_port_info* > >>>> + * to be filled with the resources information of the port. > >>>> + * @param[out] error > >>>> + * Perform verbose error reporting if not NULL. > >>>> + * PMDs initialize this structure in case of error only. > >>>> + * > >>>> + * @return > >>>> + * 0 on success, a negative errno value otherwise and rte_errno is > >>>> set. > >>> > >>> If I'm not mistakes we should be explicit with > >>> negative result values menting > >>> > > I'm not sure, until now we didn't have any errors values defined in RTE flow. > > I don't want to enforce PMD with the error types. > > If PMD can say that it can give better error code or add a case that may result in > > error, I don't want to change the API. > > So I think we better leave the error codes out of documentation unless they are final and can only > > be resulted from the rte_level. > > It is not helpful for application. If so, application don't > know how to interpret and handle various error codes. Yes rte_flow error codes are not listed (except for rte_flow_validate and indirect action). As a consequence, the error code is mainly for debug purposes. I am OK with being consistent and not listing error codes in these new functions for now. For consistency, I suggest removing error codes from rte_flow_async_action_handle_* in this patchset. We should have a general discussion about error codes handling later. It may be a design decision to allow flexibility to PMDs. If we want to provide some detailed error handling to applications, we could list main or all kind of errors. Anyway, this inconsistency is not new, so it should not block the patches IMHO.