From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 9D22E2C4F for ; Wed, 28 Dec 2016 03:52:39 +0100 (CET) Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga105.fm.intel.com with ESMTP; 27 Dec 2016 18:52:38 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,420,1477983600"; d="scan'208";a="1105062145" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by fmsmga002.fm.intel.com with ESMTP; 27 Dec 2016 18:52:38 -0800 Received: from fmsmsx122.amr.corp.intel.com (10.18.125.37) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.248.2; Tue, 27 Dec 2016 18:52:38 -0800 Received: from shsmsx104.ccr.corp.intel.com (10.239.4.70) by fmsmsx122.amr.corp.intel.com (10.18.125.37) with Microsoft SMTP Server (TLS) id 14.3.248.2; Tue, 27 Dec 2016 18:52:38 -0800 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.20]) by SHSMSX104.ccr.corp.intel.com ([10.239.4.70]) with mapi id 14.03.0248.002; Wed, 28 Dec 2016 10:52:15 +0800 From: "Wu, Jingjing" To: "Xing, Beilei" , "Zhang, Helin" CC: "dev@dpdk.org" Thread-Topic: [PATCH v2 07/17] net/i40e: add flow validate function Thread-Index: AQHSYApJZAWIBvNQC0ul8zdXmU8/aKEcpmbg Date: Wed, 28 Dec 2016 02:52:14 +0000 Message-ID: <9BB6961774997848B5B42BEC655768F810CC00A6@SHSMSX103.ccr.corp.intel.com> References: <1480679625-4157-1-git-send-email-beilei.xing@intel.com> <1482819984-14120-1-git-send-email-beilei.xing@intel.com> <1482819984-14120-8-git-send-email-beilei.xing@intel.com> In-Reply-To: <1482819984-14120-8-git-send-email-beilei.xing@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 07/17] net/i40e: add flow validate function 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: Wed, 28 Dec 2016 02:52:40 -0000 >=20 > +union i40e_filter_t { > + struct rte_eth_ethertype_filter ethertype_filter; > + struct rte_eth_fdir_filter fdir_filter; > + struct rte_eth_tunnel_filter_conf tunnel_filter; } cons_filter; > + > +typedef int (*parse_filter_t)(struct rte_eth_dev *dev, > + const struct rte_flow_attr *attr, > + const struct rte_flow_item pattern[], > + const struct rte_flow_action actions[], > + struct rte_flow_error *error, > + union i40e_filter_t *filter); You can use void* instead of define union i40e_filter_t. > +struct i40e_valid_pattern { > + enum rte_flow_item_type *items; What the item points to? Add few comments=20 > + > + ret =3D parse_filter(dev, attr, items, actions, error, &cons_filter); Will you use cons_filter later? If not, it looks like we don't need the arg= ument at all. > + > + rte_free(items); > + > + return ret; > +} > -- > 2.5.5