From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id C06A758EC for ; Thu, 16 May 2019 10:18:02 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 0882C308FC4B; Thu, 16 May 2019 08:18:02 +0000 (UTC) Received: from [10.36.112.43] (ovpn-112-43.ams2.redhat.com [10.36.112.43]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E1B4F5D6A9; Thu, 16 May 2019 08:18:00 +0000 (UTC) To: Mesut Ali Ergin , beilei.xing@intel.com, qi.z.zhang@intel.com Cc: dev@dpdk.org References: <1557980885-183777-1-git-send-email-mesut.a.ergin@intel.com> <1557980885-183777-4-git-send-email-mesut.a.ergin@intel.com> From: Maxime Coquelin Message-ID: Date: Thu, 16 May 2019 10:17:59 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <1557980885-183777-4-git-send-email-mesut.a.ergin@intel.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.43]); Thu, 16 May 2019 08:18:02 +0000 (UTC) Subject: Re: [dpdk-dev] [PATCH 3/3] net/i40e: fix inadvertent override of vector RX allowance X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 May 2019 08:18:03 -0000 On 5/16/19 6:28 AM, Mesut Ali Ergin wrote: > When i40e_rx_vec_dev_conf_condition_check_default() determines whether > vector receive functions would be allowed during initialization phase, > it should honor previously recorded disallowance during configuration > phase, and not override simply because it is for the first queue. > > Signed-off-by: Mesut Ali Ergin > --- > drivers/net/i40e/i40e_rxtx_vec_common.h | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/net/i40e/i40e_rxtx_vec_common.h b/drivers/net/i40e/i40e_rxtx_vec_common.h > index 0e6ffa0..f30cab4 100644 > --- a/drivers/net/i40e/i40e_rxtx_vec_common.h > +++ b/drivers/net/i40e/i40e_rxtx_vec_common.h > @@ -212,6 +212,10 @@ i40e_rx_vec_dev_conf_condition_check_default(struct rte_eth_dev *dev) > if (rxmode->offloads & DEV_RX_OFFLOAD_VLAN_EXTEND) > return -1; > > + /* Should not override if vector was already disallowed */ > + if (!ad->rx_vec_allowed) > + return -1; nit: wrong indentation. > + > /** > * Vector mode is allowed only when number of Rx queue > * descriptor is power of 2. > From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 9B499A00E6 for ; Thu, 16 May 2019 10:18:03 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 623295B1E; Thu, 16 May 2019 10:18:03 +0200 (CEST) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id C06A758EC for ; Thu, 16 May 2019 10:18:02 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 0882C308FC4B; Thu, 16 May 2019 08:18:02 +0000 (UTC) Received: from [10.36.112.43] (ovpn-112-43.ams2.redhat.com [10.36.112.43]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E1B4F5D6A9; Thu, 16 May 2019 08:18:00 +0000 (UTC) To: Mesut Ali Ergin , beilei.xing@intel.com, qi.z.zhang@intel.com Cc: dev@dpdk.org References: <1557980885-183777-1-git-send-email-mesut.a.ergin@intel.com> <1557980885-183777-4-git-send-email-mesut.a.ergin@intel.com> From: Maxime Coquelin Message-ID: Date: Thu, 16 May 2019 10:17:59 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <1557980885-183777-4-git-send-email-mesut.a.ergin@intel.com> Content-Type: text/plain; charset="UTF-8"; format="flowed" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.43]); Thu, 16 May 2019 08:18:02 +0000 (UTC) Subject: Re: [dpdk-dev] [PATCH 3/3] net/i40e: fix inadvertent override of vector RX allowance X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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" Message-ID: <20190516081759.wzyaYZr-59UP8R4bg84S8bOgiGc-PqXePzp22mN4_Gs@z> On 5/16/19 6:28 AM, Mesut Ali Ergin wrote: > When i40e_rx_vec_dev_conf_condition_check_default() determines whether > vector receive functions would be allowed during initialization phase, > it should honor previously recorded disallowance during configuration > phase, and not override simply because it is for the first queue. > > Signed-off-by: Mesut Ali Ergin > --- > drivers/net/i40e/i40e_rxtx_vec_common.h | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/net/i40e/i40e_rxtx_vec_common.h b/drivers/net/i40e/i40e_rxtx_vec_common.h > index 0e6ffa0..f30cab4 100644 > --- a/drivers/net/i40e/i40e_rxtx_vec_common.h > +++ b/drivers/net/i40e/i40e_rxtx_vec_common.h > @@ -212,6 +212,10 @@ i40e_rx_vec_dev_conf_condition_check_default(struct rte_eth_dev *dev) > if (rxmode->offloads & DEV_RX_OFFLOAD_VLAN_EXTEND) > return -1; > > + /* Should not override if vector was already disallowed */ > + if (!ad->rx_vec_allowed) > + return -1; nit: wrong indentation. > + > /** > * Vector mode is allowed only when number of Rx queue > * descriptor is power of 2. >