From patchwork Thu May 16 04:28:05 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Ergin, Mesut A" X-Patchwork-Id: 53461 X-Patchwork-Delegate: qi.z.zhang@intel.com Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 136915F1A; Thu, 16 May 2019 06:28:33 +0200 (CEST) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id 33495326C for ; Thu, 16 May 2019 06:28:26 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 15 May 2019 21:28:23 -0700 X-ExtLoop1: 1 Received: from skx-pink.jf.intel.com ([10.54.80.236]) by orsmga001.jf.intel.com with ESMTP; 15 May 2019 21:28:23 -0700 From: Mesut Ali Ergin To: beilei.xing@intel.com, qi.z.zhang@intel.com Cc: dev@dpdk.org, Mesut Ali Ergin Date: Wed, 15 May 2019 21:28:05 -0700 Message-Id: <1557980885-183777-4-git-send-email-mesut.a.ergin@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1557980885-183777-1-git-send-email-mesut.a.ergin@intel.com> References: <1557980885-183777-1-git-send-email-mesut.a.ergin@intel.com> Subject: [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" 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; + /** * Vector mode is allowed only when number of Rx queue * descriptor is power of 2.