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 A3927A0543; Thu, 15 Dec 2022 02:56:46 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5238C40684; Thu, 15 Dec 2022 02:56:46 +0100 (CET) Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by mails.dpdk.org (Postfix) with ESMTP id 813B2400D6 for ; Thu, 15 Dec 2022 02:56:44 +0100 (CET) Received: from kwepemi500017.china.huawei.com (unknown [172.30.72.56]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4NXb0r3y9LzRq4D; Thu, 15 Dec 2022 09:55:40 +0800 (CST) Received: from [10.67.103.235] (10.67.103.235) by kwepemi500017.china.huawei.com (7.221.188.110) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Thu, 15 Dec 2022 09:56:42 +0800 Subject: Re: [PATCH 1/2] net/hns3: declare support rule keep capability To: Chengwen Feng , , , References: <20221215014142.15750-1-fengchengwen@huawei.com> <20221215014142.15750-2-fengchengwen@huawei.com> CC: , , , From: Dongdong Liu Message-ID: Date: Thu, 15 Dec 2022 09:56:41 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: <20221215014142.15750-2-fengchengwen@huawei.com> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.67.103.235] X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To kwepemi500017.china.huawei.com (7.221.188.110) X-CFilter-Loop: Reflected 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 Acked-by: Dongdong Liu Thanks, Dongdong On 2022/12/15 9:41, Chengwen Feng wrote: > The driver supports create flow rules when device is stopped, and > re-setup flow rules when restarting, so declare support > RTE_ETH_DEV_CAPA_FLOW_RULE_KEEP. > > The driver also supports to create indirect actions when device is > stopped, and keeps the indirect actions when restarting, so declare > support RTE_ETH_DEV_CAPA_FLOW_SHARED_OBJECT_KEEP. > > Cc: stable@dpdk.org > > Signed-off-by: Chengwen Feng > --- > drivers/net/hns3/hns3_common.c | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/drivers/net/hns3/hns3_common.c b/drivers/net/hns3/hns3_common.c > index 7adc6a4972..da0a481f15 100644 > --- a/drivers/net/hns3/hns3_common.c > +++ b/drivers/net/hns3/hns3_common.c > @@ -90,10 +90,11 @@ hns3_dev_infos_get(struct rte_eth_dev *eth_dev, struct rte_eth_dev_info *info) > if (hns3_dev_get_support(hw, OUTER_UDP_CKSUM)) > info->tx_offload_capa |= RTE_ETH_TX_OFFLOAD_OUTER_UDP_CKSUM; > > + info->dev_capa = RTE_ETH_DEV_CAPA_FLOW_RULE_KEEP | > + RTE_ETH_DEV_CAPA_FLOW_SHARED_OBJECT_KEEP; > if (hns3_dev_get_support(hw, INDEP_TXRX)) > - info->dev_capa = RTE_ETH_DEV_CAPA_RUNTIME_RX_QUEUE_SETUP | > - RTE_ETH_DEV_CAPA_RUNTIME_TX_QUEUE_SETUP; > - info->dev_capa &= ~RTE_ETH_DEV_CAPA_FLOW_RULE_KEEP; > + info->dev_capa |= RTE_ETH_DEV_CAPA_RUNTIME_RX_QUEUE_SETUP | > + RTE_ETH_DEV_CAPA_RUNTIME_TX_QUEUE_SETUP; > > if (hns3_dev_get_support(hw, PTP)) > info->rx_offload_capa |= RTE_ETH_RX_OFFLOAD_TIMESTAMP; >