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 9282DA0C41; Sun, 7 Nov 2021 12:03:53 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 18FB040151; Sun, 7 Nov 2021 12:03:53 +0100 (CET) Received: from eva.fit.vutbr.cz (eva.fit.vutbr.cz [147.229.176.14]) by mails.dpdk.org (Postfix) with ESMTP id 6497D40040 for ; Sun, 7 Nov 2021 12:03:51 +0100 (CET) Received: from roundcube.fit.vutbr.cz (spytihnev.fit.vutbr.cz [IPv6:2001:67c:1220:809:0:0:93e5:9e2]) (authenticated bits=0) by eva.fit.vutbr.cz (8.16.1/8.16.1) with ESMTPSA id 1A7B3cxG087860 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Sun, 7 Nov 2021 12:03:38 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=stud.fit.vutbr.cz; s=studfit; t=1636283021; bh=NyIF7RTaWLheywOnjhtNPtHTUHzQyOGoRYXU9FDaVfQ=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=dZ6/BajoIp4SJhEn+vuKvuy7Anx7fllXqV+PrRTRs7BlXY+7nVBhL5aqU41qqQyGU fh1knGp29/gKBuJ7ZsFcxwjuIiLk2AZ2X79XBFcvlJ/Ykc7vVNYj8ppuV4n59erd6F SCjAfImOtDoldpk7sxylpnhm9amp3uETSbMVmIzo= MIME-Version: 1.0 Date: Sun, 07 Nov 2021 12:03:38 +0100 From: =?UTF-8?Q?Havl=C3=ADk_Martin?= To: Ferruh Yigit Cc: Jan Viktorin , dev@dpdk.org, chas3@att.com, humin29@huawei.com, thomas@monjalon.net, andrew.rybchenko@oktetlabs.ru, haiyue.wang@intel.com, ivan.ilchenko@oktetlabs.ru, aman.deep.singh@intel.com, kirankn@juniper.net, lirongqing@baidu.com, ajit.khaparde@broadcom.com, Ori Kam , Dmitry Kozlyuk In-Reply-To: <6c5a60db-4062-ad0f-5298-baa91553a1f1@intel.com> References: <20211005171613.2879-1-xhavli56@stud.fit.vutbr.cz> <6c5a60db-4062-ad0f-5298-baa91553a1f1@intel.com> User-Agent: Roundcube Webmail Message-ID: <012de0bf4972b7c2f4534043038b451c@stud.fit.vutbr.cz> X-Sender: xhavli56@stud.fit.vutbr.cz Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH 0/2] net/bonding: fix dedicated queues flow rule issue 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" Dne 2021-10-27 11:55, Ferruh Yigit napsal: > On 10/5/2021 6:16 PM, Martin Havlik wrote: >> This patchset stems from [1]. >> >> Not all PMDs allow RTE flow rule creation before device start. >> Introduced capability marks the ones that allow it. >> The capability is then used to fix flow rule creation for >> dedicated queues in slave devices in bonding. >> >> The introduced capa _will need to be set_ for all appropriate PMDs >> in `rte_eth_dev_info->dev_capa`. >> That is not pretty, but it holds the semantics of a capability >> correctly, as opposed to making it a requirement to have the device >> started before creating flow rules. >> > > +Ori & Dmitry. > > I think right now the method to check if device supports adding flow > rules when stopped is run 'rte_flow_create()' when device is stopped > and check return value. > > Can we do similar in the bonding? It might be a possible solution. The only thing I'm not sure about is that different PMDs may require different flow rule specifications for the rule to be valid, e.g. what pattern and action to set to this tryout flow rule? We would have to make sure the rule can be created on any PMD so failure would mean only one thing - device doesn't support creating flow rules when stopped. Is that possible? Is it already a thing that is used somewhere? > > I am not clear if there is an error to differentiate flow create is > failed because device is stopped (or from some other reason). > > > And other option is, what happens if rule is always created after > device started? That is what I originally proposed [here], but it didn't gain much favour so the idea got lost in the discussion. [here] https://mails.dpdk.org/archives/dev/2021-June/212210.html > >> [1] https://www.mail-archive.com/dev@dpdk.org/msg214840.html >> >> Martin Havlik (2): >> lib/ethdev: introduce RTE_ETH_DEV_CAPA_FLOW_CREATE_BEFORE_START >> net/bonding: require started device for dedicated queues >> >> drivers/net/bonding/rte_eth_bond_pmd.c | 25 >> +++++++++++++++++++------ >> lib/ethdev/rte_ethdev.h | 2 ++ >> 2 files changed, 21 insertions(+), 6 deletions(-) >>