From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 671511518 for ; Thu, 27 Nov 2014 06:21:37 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga102.jf.intel.com with ESMTP; 26 Nov 2014 21:19:07 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.07,467,1413270000"; d="scan'208";a="644311059" Received: from pgsmsx102.gar.corp.intel.com ([10.221.44.80]) by orsmga002.jf.intel.com with ESMTP; 26 Nov 2014 21:21:35 -0800 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by PGSMSX102.gar.corp.intel.com (10.221.44.80) with Microsoft SMTP Server (TLS) id 14.3.195.1; Thu, 27 Nov 2014 13:21:32 +0800 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.110]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.240]) with mapi id 14.03.0195.001; Thu, 27 Nov 2014 13:21:32 +0800 From: "Qiu, Michael" To: "Wu, Jingjing" , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH v3 1/2] ethdev: new structure of Ethertype Filter for filter_ctrl api Thread-Index: AQHP/0CG4tDT93DA9Eei3y+TGn/LsA== Date: Thu, 27 Nov 2014 05:21:30 +0000 Message-ID: <533710CFB86FA344BFBF2D6802E60286C9AC77@SHSMSX101.ccr.corp.intel.com> References: <1413965977-15165-1-git-send-email-jingjing.wu@intel.com> <1415882995-8697-1-git-send-email-jingjing.wu@intel.com> <1415882995-8697-2-git-send-email-jingjing.wu@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 v3 1/2] ethdev: new structure of Ethertype Filter for filter_ctrl api X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Nov 2014 05:21:37 -0000 On 11/13/2014 8:51 PM, Jingjing Wu wrote:=0A= > From: "jingjing.wu" =0A= >=0A= > A new structure of ethertype filter is defined in rte_eth_ctrl.h=0A= > for filter_ctrl api=0A= >=0A= > Signed-off-by: jingjing.wu =0A= > ---=0A= > lib/librte_ether/rte_eth_ctrl.h | 20 ++++++++++++++++++++=0A= > 1 file changed, 20 insertions(+)=0A= >=0A= > diff --git a/lib/librte_ether/rte_eth_ctrl.h b/lib/librte_ether/rte_eth_c= trl.h=0A= > index 8dd384d..73bc296 100644=0A= > --- a/lib/librte_ether/rte_eth_ctrl.h=0A= > +++ b/lib/librte_ether/rte_eth_ctrl.h=0A= > @@ -53,6 +53,7 @@ enum rte_filter_type {=0A= > RTE_ETH_FILTER_NONE =3D 0,=0A= > RTE_ETH_FILTER_MACVLAN,=0A= > RTE_ETH_FILTER_TUNNEL,=0A= > + RTE_ETH_FILTER_ETHERTYPE,=0A= > RTE_ETH_FILTER_MAX=0A= > };=0A= > =0A= > @@ -155,6 +156,25 @@ struct rte_eth_tunnel_filter_conf {=0A= > uint16_t queue_id; /** < queue number. */=0A= > };=0A= > =0A= > +/**=0A= > + * Define all structures for Ethertype Filter type.=0A= > + */=0A= > +=0A= > +#define RTE_ETHTYPE_FLAGS_MAC 0x0001 /**< If set, compare mac */=0A= > +#define RTE_ETHTYPE_FLAGS_DROP 0x0002 /**< If set, drop packet when ma= tch */=0A= > +=0A= > +/**=0A= > + * A structure used to define the ethertype filter entry=0A= > + * to support RTE_ETH_FILTER_ETHERTYPE with RTE_ETH_FILTER_ADD,=0A= > + * RTE_ETH_FILTER_DELETE and RTE_ETH_FILTER_GET operations.=0A= > + */=0A= > +struct rte_eth_ethertype_filter {=0A= > + struct ether_addr mac_addr; /**< Mac address to match. */=0A= > + uint16_t ether_type; /**< Ether type to match */=0A= > + uint16_t flags; /**< Flags from RTE_ETHTYPE_FLAGS_* */=0A= > + uint16_t queue; /**< Queue assigned to when match*/=0A= =0A= Here 'match*/' should be 'match */', ignore this if it is just my email=0A= client's display issue :)=0A= =0A= Thanks,=0A= Michael=0A= > +};=0A= > +=0A= > #ifdef __cplusplus=0A= > }=0A= > #endif=0A= =0A=