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 02C50A0487 for ; Tue, 2 Jul 2019 11:51:58 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id CE2BE5B34; Tue, 2 Jul 2019 11:51:57 +0200 (CEST) Received: from EUR03-DB5-obe.outbound.protection.outlook.com (mail-eopbgr40070.outbound.protection.outlook.com [40.107.4.70]) by dpdk.org (Postfix) with ESMTP id BBA612BC8 for ; Tue, 2 Jul 2019 11:51:56 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=1+ZiC4RQgFmXYbEnIZFljcfpumAqvmLinXnT9/oZdPM=; b=ntwRgFIRJALrwmaquhny6MxVIYSirIYLMiZnjAm6TRs2fgezrMdRT5zs1du/ZZP++1fRVRxjfQTbfKJ2N/m1nOLVcj+4d9/yBQvgZeMpX4OlI4t1QbOgOFJbIHPZTB0EfAUuILcAXznsz2jgPEDLj590p6yawD0DY8vv1+jYoYI= Received: from AM4PR05MB3425.eurprd05.prod.outlook.com (10.171.190.15) by AM4SPR01MB267.eurprd05.prod.outlook.com (10.171.191.140) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2032.20; Tue, 2 Jul 2019 09:51:55 +0000 Received: from AM4PR05MB3425.eurprd05.prod.outlook.com ([fe80::d12a:4df1:37d7:cc06]) by AM4PR05MB3425.eurprd05.prod.outlook.com ([fe80::d12a:4df1:37d7:cc06%7]) with mapi id 15.20.2032.019; Tue, 2 Jul 2019 09:51:55 +0000 From: Ori Kam To: Jack Min , Adrien Mazarguil , John McNamara , Marko Kovacevic , Thomas Monjalon , Ferruh Yigit , Andrew Rybchenko CC: "dev@dpdk.org" Thread-Topic: [PATCH v4 1/4] ethdev: add GRE key field to flow API Thread-Index: AdUwu6rBjvCro17WTeyQLIYDFw3syA== Date: Tue, 2 Jul 2019 09:51:55 +0000 Message-ID: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=orika@mellanox.com; x-originating-ip: [193.47.165.251] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 0cb25d9f-fade-4aa4-c7d9-08d6fed2eaa7 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(4618075)(2017052603328)(7193020); SRVR:AM4SPR01MB267; x-ms-traffictypediagnostic: AM4SPR01MB267: x-ld-processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtAddr x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:5516; x-forefront-prvs: 008663486A x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(376002)(136003)(366004)(346002)(39860400002)(396003)(13464003)(199004)(189003)(7736002)(316002)(14454004)(110136005)(68736007)(74316002)(2906002)(305945005)(229853002)(64756008)(66446008)(66476007)(81166006)(66556008)(71200400001)(71190400001)(76116006)(8936002)(73956011)(81156014)(52536014)(33656002)(3846002)(66946007)(6116002)(6246003)(86362001)(66066001)(53546011)(99286004)(25786009)(102836004)(4326008)(5660300002)(7696005)(6506007)(256004)(14444005)(6436002)(9686003)(186003)(486006)(476003)(53936002)(26005)(478600001)(8676002)(55016002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM4SPR01MB267; H:AM4PR05MB3425.eurprd05.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: 2hR6asIZtIZaboWUBHmmByLIOImrD2dGf2OCjp0TqtRIt8wRTENxihlGINKeAbfvFxo6KbI50/YP1giDsfigmjHSr8nbN6lRZFctz8kfkc0o0QyqP9Q6SvGPZPizJ7OZnUs+iRa0srTiDJ9kBwu9kf0vXBgppY81S0t+R0AXKBw5zj5ICXkKmsYC44a0sR9OMRsn8B6i3vAIyFoCp3LWpay+TQitz+Tsu+Y4Bo1/VHZ2huPTtBgZ2qm90Fc/fKlSiuv+D30kV/Jjm76zY7KxXWU2/4qdMPx015UWQhapT335i6NGjX1RU1SI6DTvgsGyM8OGgVfBMWBNBg4EpF2SeoNQW0RboocJRymZ0oqw/C20VhNQEuopeMpa4S8tIvLE0g2i+Mw8d2n7fb8DfkfQCtcNGdgs3MlHNG37NIV+a4E= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0cb25d9f-fade-4aa4-c7d9-08d6fed2eaa7 X-MS-Exchange-CrossTenant-originalarrivaltime: 02 Jul 2019 09:51:55.1935 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: orika@mellanox.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM4SPR01MB267 Subject: Re: [dpdk-dev] [PATCH v4 1/4] ethdev: add GRE key field to flow API 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: Xiaoyu Min > Sent: Tuesday, July 2, 2019 12:46 PM > To: Ori Kam ; Adrien Mazarguil > ; John McNamara > ; Marko Kovacevic > ; Thomas Monjalon ; > Ferruh Yigit ; Andrew Rybchenko > > Cc: dev@dpdk.org > Subject: [Suspected-Phishing][PATCH v4 1/4] ethdev: add GRE key field to = flow > API >=20 > Add new rte_flow_item_gre_key in order to match the optional key field. >=20 > Signed-off-by: Xiaoyu Min > --- Acked-by: Ori Kam Thanks, Ori Kam. > doc/guides/prog_guide/rte_flow.rst | 8 ++++++++ > lib/librte_ethdev/rte_flow.c | 1 + > lib/librte_ethdev/rte_flow.h | 7 +++++++ > 3 files changed, 16 insertions(+) >=20 > diff --git a/doc/guides/prog_guide/rte_flow.rst > b/doc/guides/prog_guide/rte_flow.rst > index a34d012e55..f4b7baa3c3 100644 > --- a/doc/guides/prog_guide/rte_flow.rst > +++ b/doc/guides/prog_guide/rte_flow.rst > @@ -980,6 +980,14 @@ Matches a GRE header. > - ``protocol``: protocol type. > - Default ``mask`` matches protocol only. >=20 > +Item: ``GRE_KEY`` > +^^^^^^^^^^^^^^^^^ > + > +Matches a GRE key field. > +This should be preceded by item ``GRE`` > + > +- Value to be matched is a big-endian 32 bit integer > + > Item: ``FUZZY`` > ^^^^^^^^^^^^^^^ >=20 > diff --git a/lib/librte_ethdev/rte_flow.c b/lib/librte_ethdev/rte_flow.c > index 3277be1edb..f3e56d0bbe 100644 > --- a/lib/librte_ethdev/rte_flow.c > +++ b/lib/librte_ethdev/rte_flow.c > @@ -55,6 +55,7 @@ static const struct rte_flow_desc_data > rte_flow_desc_item[] =3D { > MK_FLOW_ITEM(NVGRE, sizeof(struct rte_flow_item_nvgre)), > MK_FLOW_ITEM(MPLS, sizeof(struct rte_flow_item_mpls)), > MK_FLOW_ITEM(GRE, sizeof(struct rte_flow_item_gre)), > + MK_FLOW_ITEM(GRE_KEY, sizeof(rte_be32_t)), > MK_FLOW_ITEM(FUZZY, sizeof(struct rte_flow_item_fuzzy)), > MK_FLOW_ITEM(GTP, sizeof(struct rte_flow_item_gtp)), > MK_FLOW_ITEM(GTPC, sizeof(struct rte_flow_item_gtp)), > diff --git a/lib/librte_ethdev/rte_flow.h b/lib/librte_ethdev/rte_flow.h > index f3a8fb103f..5d3702a44c 100644 > --- a/lib/librte_ethdev/rte_flow.h > +++ b/lib/librte_ethdev/rte_flow.h > @@ -289,6 +289,13 @@ enum rte_flow_item_type { > */ > RTE_FLOW_ITEM_TYPE_GRE, >=20 > + /** > + * Matches a GRE optional key field. > + * > + * The value should a big-endian 32bit integer. > + */ > + RTE_FLOW_ITEM_TYPE_GRE_KEY, > + > /** > * [META] > * > -- > 2.21.0