From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id CBCEB1B170 for ; Mon, 8 Jan 2018 06:41:34 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 07 Jan 2018 21:41:33 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.46,329,1511856000"; d="scan'208";a="25278438" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by orsmga002.jf.intel.com with ESMTP; 07 Jan 2018 21:41:32 -0800 Received: from fmsmsx125.amr.corp.intel.com (10.18.125.40) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.319.2; Sun, 7 Jan 2018 21:41:33 -0800 Received: from shsmsx102.ccr.corp.intel.com (10.239.4.154) by FMSMSX125.amr.corp.intel.com (10.18.125.40) with Microsoft SMTP Server (TLS) id 14.3.319.2; Sun, 7 Jan 2018 21:41:33 -0800 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.159]) by shsmsx102.ccr.corp.intel.com ([169.254.2.189]) with mapi id 14.03.0319.002; Mon, 8 Jan 2018 13:41:30 +0800 From: "Xing, Beilei" To: "Rybalchenko, Kirill" , "dev@dpdk.org" CC: "Rybalchenko, Kirill" , "Chilikin, Andrey" , "Wu, Jingjing" Thread-Topic: [dpdk-dev] [PATCH v2] net/i40e: do not turn on flexible payload on driver init Thread-Index: AQHThYPmf8Ck8J4J5kWbp4phUJFMkqNpeR0g Date: Mon, 8 Jan 2018 05:41:30 +0000 Message-ID: <94479800C636CB44BD422CB454846E01320884DD@SHSMSX101.ccr.corp.intel.com> References: <1512142049-122930-1-git-send-email-kirill.rybalchenko@intel.com> <1515087906-2893-1-git-send-email-kirill.rybalchenko@intel.com> In-Reply-To: <1515087906-2893-1-git-send-email-kirill.rybalchenko@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v2] net/i40e: do not turn on flexible payload on driver init 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: Mon, 08 Jan 2018 05:41:35 -0000 > -----Original Message----- > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Kirill Rybalchenko > Sent: Friday, January 5, 2018 1:45 AM > To: dev@dpdk.org > Cc: Rybalchenko, Kirill ; Chilikin, Andrey > ; Xing, Beilei ; Wu, > Jingjing > Subject: [dpdk-dev] [PATCH v2] net/i40e: do not turn on flexible payload = on > driver init >=20 > Function i40e_GLQF_reg_init() overwrites global register for flexible pay= load, > forcing extraction of first 16 bytes of > L2/L3/L4 payload to the field vector even if flexible payload is not used= by an > application. Such unconditional turn on of flexible payload effectively > disables ability to use outer IP Destination address for RSS/FDIR for tun= nelled > packets, as flexible payload overwrites outer IP destination address on t= he > field vector. >=20 > Now flexible payload turned on only when flow director is enabled and > configured. >=20 > v1: > Global registers will be set only when payload is enabled. > They will be reset if payload is disabled or on port reset (uninit). >=20 > v2: > dev_init and dev_close disable flexible payload by default. > Flexible payload enabled selectively, only if appropriate PIT is set up. = The > same done for FDIR and for rte_flow API. >=20 > Signed-off-by: Kirill Rybalchenko > --- > drivers/net/i40e/i40e_ethdev.c | 29 ++++++++++++++++++----------- > drivers/net/i40e/i40e_ethdev.h | 1 + > drivers/net/i40e/i40e_fdir.c | 14 +++++++++++--- > drivers/net/i40e/i40e_flow.c | 9 ++++++++- > 4 files changed, 38 insertions(+), 15 deletions(-) >=20 > diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethde= v.c > index 811cc9f..b136120 100644 > --- a/drivers/net/i40e/i40e_ethdev.c > +++ b/drivers/net/i40e/i40e_ethdev.c > @@ -701,17 +701,6 @@ RTE_PMD_REGISTER_KMOD_DEP(net_i40e, "* > igb_uio | uio_pci_generic | vfio-pci"); static inline void > i40e_GLQF_reg_init(struct i40e_hw *hw) { > /* > - * Force global configuration for flexible payload > - * to the first 16 bytes of the corresponding L2/L3/L4 paylod. > - * This should be removed from code once proper > - * configuration API is added to avoid configuration conflicts > - * between ports of the same device. > - */ > - I40E_WRITE_REG(hw, I40E_GLQF_ORT(33), 0x000000E0); > - I40E_WRITE_REG(hw, I40E_GLQF_ORT(34), 0x000000E3); > - I40E_WRITE_REG(hw, I40E_GLQF_ORT(35), 0x000000E6); > - Please also help to change the comment in eth_i40e_dev_init where i40e_GLQF= _reg_init is involved, since this workaround is removed. Apart from that, Acked-by: Beilei Xing