From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 39096A0583; Thu, 19 Mar 2020 03:01:28 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 89B1C2C23; Thu, 19 Mar 2020 03:01:27 +0100 (CET) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id C117FE07 for ; Thu, 19 Mar 2020 03:01:24 +0100 (CET) IronPort-SDR: xGMvtyVNo3/QolEh1R1Iq0iXEqXixg5UYDnzuZ+o6y8+E7WrW+RuaYzx7E7KCvIoOCD9s+gQlg B0UnKN2p52TA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Mar 2020 19:01:23 -0700 IronPort-SDR: gVlOkNwUpWyoOAuTQ5u6FseihD73NFpEM9P9L9yhiIym7eB79S2hVmbHOTD0kcxUBROPZPkovL w9pdNsj+Andw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,569,1574150400"; d="scan'208";a="324368161" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by orsmga001.jf.intel.com with ESMTP; 18 Mar 2020 19:01:23 -0700 Received: from FMSMSX109.amr.corp.intel.com (10.18.116.9) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 18 Mar 2020 19:01:22 -0700 Received: from shsmsx153.ccr.corp.intel.com (10.239.6.53) by fmsmsx109.amr.corp.intel.com (10.18.116.9) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 18 Mar 2020 19:01:22 -0700 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.137]) by SHSMSX153.ccr.corp.intel.com ([169.254.12.96]) with mapi id 14.03.0439.000; Thu, 19 Mar 2020 10:01:19 +0800 From: "Zhang, Qi Z" To: "Yang, Qiming" , "dev@dpdk.org" CC: "Yang, Qiming" Thread-Topic: [dpdk-dev] [PATCH 1/2] net/iavf: support generic flow Thread-Index: AQHV/DcGlekyohk/KUSPnIrp2OZVVahPKR9g Date: Thu, 19 Mar 2020 02:01:18 +0000 Message-ID: <039ED4275CED7440929022BC67E70611547E3A07@SHSMSX103.ccr.corp.intel.com> References: <20200317081745.29450-1-qiming.yang@intel.com> <20200317081745.29450-2-qiming.yang@intel.com> In-Reply-To: <20200317081745.29450-2-qiming.yang@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.2.0.6 dlp-reaction: no-action 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 1/2] net/iavf: support generic flow 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" > -----Original Message----- > From: dev On Behalf Of Qiming Yang > Sent: Tuesday, March 17, 2020 4:18 PM > To: dev@dpdk.org > Cc: Yang, Qiming > Subject: [dpdk-dev] [PATCH 1/2] net/iavf: support generic flow >=20 > This patch added iavf_flow_create, iavf_flow_destroy, iavf_flow_flush and > iavf_flow_validate support, these are used to handle all the generic filt= ers. >=20 > This patch supported basic L2, L3, L4 and GTPU patterns. >=20 > Signed-off-by: Qiming Yang > --- > doc/guides/rel_notes/release_20_05.rst | 5 + > drivers/net/iavf/Makefile | 1 + > drivers/net/iavf/iavf.h | 9 + > drivers/net/iavf/iavf_ethdev.c | 46 ++ > drivers/net/iavf/iavf_generic_flow.c | 928 > +++++++++++++++++++++++++++++++++ > drivers/net/iavf/iavf_generic_flow.h | 279 ++++++++++ > drivers/net/iavf/meson.build | 1 + > 7 files changed, 1269 insertions(+) > create mode 100644 drivers/net/iavf/iavf_generic_flow.c > create mode 100644 drivers/net/iavf/iavf_generic_flow.h >=20 > diff --git a/doc/guides/rel_notes/release_20_05.rst > b/doc/guides/rel_notes/release_20_05.rst > index 2190eaf..44d375a 100644 > --- a/doc/guides/rel_notes/release_20_05.rst > +++ b/doc/guides/rel_notes/release_20_05.rst > @@ -56,6 +56,11 @@ New Features > Also, make sure to start the actual text at the margin. >=20 > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D >=20 > +* **Updated the Intel ice driver.** > + > + Updated the Intel ice driver with new features and improvements, > including: > + > + * Added support for DCF (Device Config Function) feature. Above comment is not related with this patch, right? >=20 > Removed Items > ------------- .... > + > +static struct iavf_flow_engine * > +iavf_parse_engine_create(struct iavf_adapter *ad, > + struct rte_flow *flow, > + struct iavf_parser_list *parser_list, > + const struct rte_flow_item pattern[], > + const struct rte_flow_action actions[], > + struct rte_flow_error *error) > +{ > + struct iavf_flow_engine *engine =3D NULL; > + struct iavf_flow_parser_node *parser_node; > + void *temp; > + void *meta =3D NULL; > + > + TAILQ_FOREACH_SAFE(parser_node, parser_list, node, temp) { > + if (parser_node->parser->parse_pattern_action(ad, > + parser_node->parser->array, > + parser_node->parser->array_len, > + pattern, actions, &meta, error) < 0) > + continue; > + > + engine =3D parser_node->parser->engine; > + if (engine->create =3D=3D NULL) { > + rte_flow_error_set(error, EINVAL, > + RTE_FLOW_ERROR_TYPE_HANDLE, > + NULL, "Invalid engine"); > + continue; > + } Please sync with below fix for ice https://patchwork.dpdk.org/patch/66232/ > + > + if (!(engine->create(ad, flow, meta, error))) > + return engine; > + } > + return NULL; > +} > + > +static struct iavf_flow_engine * > +iavf_parse_engine_validate(struct iavf_adapter *ad, > + struct rte_flow *flow, > + struct iavf_parser_list *parser_list, > + const struct rte_flow_item pattern[], > + const struct rte_flow_action actions[], > + struct rte_flow_error *error) > +{ > + struct iavf_flow_engine *engine =3D NULL; > + struct iavf_flow_parser_node *parser_node; > + void *temp; > + void *meta =3D NULL; > + > + TAILQ_FOREACH_SAFE(parser_node, parser_list, node, temp) { > + if (parser_node->parser->parse_pattern_action(ad, > + parser_node->parser->array, > + parser_node->parser->array_len, > + pattern, actions, &meta, error) < 0) > + continue; > + Please sync with below fix for ice https://patchwork.dpdk.org/patch/66232/ > + engine =3D parser_node->parser->engine; > + if (engine->validation =3D=3D NULL) { > + rte_flow_error_set(error, EINVAL, > + RTE_FLOW_ERROR_TYPE_HANDLE, > + NULL, "Validation not support"); > + continue; > + }