From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id 941C628EE for ; Mon, 22 May 2017 15:53:31 +0200 (CEST) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 22 May 2017 06:53:30 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.38,377,1491289200"; d="scan'208";a="105444249" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.237.220.81]) ([10.237.220.81]) by fmsmga006.fm.intel.com with ESMTP; 22 May 2017 06:53:28 -0700 To: "Iremonger, Bernard" , "dev@dpdk.org" Cc: "Mcnamara, John" , "Tahhan, Maryam" References: <20170420185448.19162-1-ferruh.yigit@intel.com> <20170518181203.15244-1-ferruh.yigit@intel.com> <8CEF83825BEC744B83065625E567D7C224D5F20E@IRSMSX108.ger.corp.intel.com> From: Ferruh Yigit Message-ID: <7428261c-4276-1d28-63c2-3a51a583cdf9@intel.com> Date: Mon, 22 May 2017 14:53:28 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: <8CEF83825BEC744B83065625E567D7C224D5F20E@IRSMSX108.ger.corp.intel.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] [RFC v2] Flow classification library 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, 22 May 2017 13:53:32 -0000 On 5/19/2017 5:30 PM, Iremonger, Bernard wrote: > Hi Ferruh, > >> -----Original Message----- >> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Ferruh Yigit >> Sent: Thursday, May 18, 2017 7:12 PM >> To: dev@dpdk.org >> Cc: Yigit, Ferruh ; Mcnamara, John >> ; Tahhan, Maryam >> >> Subject: [dpdk-dev] [RFC v2] Flow classification library >> >> DPDK works with packets, but some network administration tools works >> based on flow information. >> >> This library is suggested to provide helper API to convert packet based >> information to the flow records. >> >> Basically the library consist of a single API that gets packets, flow definition >> and action as parameter and provides flow stats based on action. Application >> should call the API for all received packets. >> >> Library header file has more comments on how library works and provided >> APIs. >> >> Packets to flow conversion will cause performance drop, that is why >> conversion done on demand by an API call provided by this library. >> >> Initial implementation in mind is to provide support for IPFIX metering >> process but library planned to be as generic as possible. And flow information >> provided by this library is missing to implement full IPFIX features, but this is >> planned to be initial step. >> >> Flows are defined using rte_flow, also measurements (actions) are provided >> by rte_flow. To support more IPFIX measurements, the implementation may >> require extending rte_flow addition to implementing this library. > > Do you know what extensions are needed to the rte_flow code? The extension may be required on two fields: 1- Defining the flow 2- Available actions For defining the flow, an update may not be required, specially at first version of the library. But for action, there may be some updates. IPFIX RFC defines Metering process as [1], (in [2]). This library should provide helper APIs to metering process. Currently only action can be used in rte_flow is COUNT, more actions can be added to help "packet header capturing, timestamping, sampling, classifying" tasks of the metering process. The exact list depends on the what will be implemented in this release. [1] Metering Process The Metering Process generates Flow Records. Inputs to the process are packet headers, characteristics, and Packet Treatment observed at one or more Observation Points. The Metering Process consists of a set of functions that includes packet header capturing, timestamping, sampling, classifying, and maintaining Flow Records. The maintenance of Flow Records may include creating new records, updating existing ones, computing Flow statistics, deriving further Flow properties, detecting Flow expiration, passing Flow Records to the Exporting Process, and deleting Flow Records. [2] https://tools.ietf.org/html/rfc7011 > >> >> Since both flows and action defined by rte_flow, it is possible to consider this >> library as rte_flow software fallback. >> >> And in case the underlying hardware supports the provided flow and action, >> in implementation details this library may prefer to use hardware support to >> get the requested stats, for the actions that are not supported by hardware >> this library will implement the ways to get the stats. >> >> It will be more beneficial to shape this library to cover more use cases, please >> feel free to comment on possible other use case and desired functionalities. >> >> >> Changes to previous version of the RFC: >> v2: >> * library uses rte_flow to define flows and action. >> * no more callbacks used, user should call API in poll mode for flow stats. >> * library no more maintain any flow data, all flow related stats returned >> by API call and forgotten. >> >> Thanks, >> ferruh >> >> cc: John McNamara >> cc: Maryam Tahhan >> >> Ferruh Yigit (1): >> flow_classify: add librte_flow_classify library >> >> config/common_base | 5 + >> doc/api/doxy-api-index.md | 1 + >> doc/api/doxy-api.conf | 1 + >> doc/guides/rel_notes/release_17_08.rst | 1 + >> lib/Makefile | 2 + >> lib/librte_flow_classify/Makefile | 50 ++++++++ >> lib/librte_flow_classify/rte_flow_classify.c | 72 ++++++++++++ >> lib/librte_flow_classify/rte_flow_classify.h | 129 >> +++++++++++++++++++++ >> .../rte_flow_classify_version.map | 7 ++ >> mk/rte.app.mk | 1 + >> 10 files changed, 269 insertions(+) >> create mode 100644 lib/librte_flow_classify/Makefile create mode 100644 >> lib/librte_flow_classify/rte_flow_classify.c >> create mode 100644 lib/librte_flow_classify/rte_flow_classify.h >> create mode 100644 lib/librte_flow_classify/rte_flow_classify_version.map >> >> -- >> 2.9.3 >