From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id 4F0E82B9C for ; Thu, 5 Jan 2017 18:47:15 +0100 (CET) Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga103.jf.intel.com with ESMTP; 05 Jan 2017 09:47:05 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,322,1477983600"; d="scan'208";a="1108471812" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.237.220.38]) ([10.237.220.38]) by fmsmga002.fm.intel.com with ESMTP; 05 Jan 2017 09:47:03 -0800 To: Beilei Xing , jingjing.wu@intel.com, helin.zhang@intel.com References: <1483500187-124740-1-git-send-email-beilei.xing@intel.com> <1483631170-16681-1-git-send-email-beilei.xing@intel.com> <1483631170-16681-11-git-send-email-beilei.xing@intel.com> Cc: dev@dpdk.org From: Ferruh Yigit Message-ID: <6c6c05a7-e58f-d784-0ec1-1dbaa7ea0158@intel.com> Date: Thu, 5 Jan 2017 17:47:03 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <1483631170-16681-11-git-send-email-beilei.xing@intel.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] [PATCH v6 10/17] net/i40e: add flow create 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: Thu, 05 Jan 2017 17:47:15 -0000 On 1/5/2017 3:46 PM, Beilei Xing wrote: > This patch adds i40e_flow_create function to create a > rule. It will check if a flow matches ethertype filter > or flow director filter or tunnel filter, if the flow > matches some kind of filter, then set the filter to HW. > > Signed-off-by: Beilei Xing > --- <...> > > /* > + * Struct to store flow created. > + */ > +struct i40e_flow { > + TAILQ_ENTRY(i40e_flow) node; > + enum rte_filter_type filter_type; > + void *rule; > +}; It is possible to define this struct as "struct rte_flow", this prevents repetitive casting between rte_flow and i40e_flow. It is your call. <...>