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 42506A2EFC for ; Thu, 19 Sep 2019 17:17:58 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 11F801F110; Thu, 19 Sep 2019 17:17:58 +0200 (CEST) Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-eopbgr140051.outbound.protection.outlook.com [40.107.14.51]) by dpdk.org (Postfix) with ESMTP id C2AF11F0EF for ; Thu, 19 Sep 2019 17:17:56 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PXbwUkqQz0wT3xgP9amNqgfwSZ4S6Hk6ciNFVYr5ZjLioTneFZljByl2BZc2duBNdl603o0hsLZYrAq9k6T9k7B1e1deFS/ZFx59uU5LpYGJYZkwDI4XvBQ7YctyoBkogymezjhPW7HzH+hkVqo3jG9QKVczq6jP3kIYsEudGyuAtLylLE+N1dWpPxCjLqdsrgFLUCdAdr44mulYf1WeLit5rKt6UkDVHToiGV/IBktfw8KOPacXG9h/ieCG4N+CiYT6h/mBceBkVm++WPt3yRMIoEDsZkNkmFTSsGLs8InzkXe1yZ9pfsCi8h715Q4tevkVkLjrQP0rbWSwSNlBqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5Uu1cnUX9c7R1jtsEYewzf+oag4bDwxojI8uUt86WU0=; b=g62PKmQXobX+6qrp7pmKZJAvd92xzRakWjP9nwouplyD5emTXvmD7a5vcdH4Zlju/atb/7xpvBac6/PA8rbP1HvHOA2EaDpjviBycTFYnyBNxc3N+qULKVEMAbs/7Waf4KL8DIW7pfRryqeEDFmyFqDkSUIsJ2Cy/awiDCea73L6xer0PBszH5kWN47Obnn6wfPTRQT/gcGUiWZkjwKTwr+1CRq1ynNSV+3X1Yh3f5EBc3b+/McFPTtJEXx7hKgnuTQ7QmYVJrldYBoOCsXiqpkHGOOwn/aKF6GrOmd3tT9X4MMLYyklf/IZwHEEywOegPjOsBzj042xee2y2eAKCg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5Uu1cnUX9c7R1jtsEYewzf+oag4bDwxojI8uUt86WU0=; b=GDdwkSlBNXu8Oe+g0gSNA03zOmAe0eQq2kXH+RrtUv1/NBbRnHssiCID0EUC487awF7A6Hjk5Xl70/sWWl9Pj57rUB0T9b75NLXrHOVirzxUNeRTkMhLS1n/u/sNYqgMAmFsD9Q0nqwSjejpFjycB0UNBVRgCimPMToSmbPUi2U= Received: from DB8PR04MB6635.eurprd04.prod.outlook.com (20.179.251.20) by DB8PR04MB7051.eurprd04.prod.outlook.com (10.141.120.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2263.14; Thu, 19 Sep 2019 15:17:56 +0000 Received: from DB8PR04MB6635.eurprd04.prod.outlook.com ([fe80::5078:877a:878f:52a]) by DB8PR04MB6635.eurprd04.prod.outlook.com ([fe80::5078:877a:878f:52a%6]) with mapi id 15.20.2263.023; Thu, 19 Sep 2019 15:17:56 +0000 From: Akhil Goyal To: "konstantin.ananyev@intel.com" CC: Hemant Agrawal , "dev@dpdk.org" Thread-Topic: [PATCH v3 3/3] examples/ipsec-secgw: support IPv6 tunnel for lookaside proto Thread-Index: AQHVY+ox9O3bwcUhlEyskMmBPCE3TqczMotQ Date: Thu, 19 Sep 2019 15:17:55 +0000 Message-ID: References: <20190805082205.10794-1-akhil.goyal@nxp.com> <20190905124807.22158-1-akhil.goyal@nxp.com> <20190905124807.22158-4-akhil.goyal@nxp.com> In-Reply-To: <20190905124807.22158-4-akhil.goyal@nxp.com> Accept-Language: en-IN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=akhil.goyal@nxp.com; x-originating-ip: [92.120.1.70] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 4d95a0f0-7c34-4156-e146-08d73d148c6e x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600167)(711020)(4605104)(1401327)(4618075)(2017052603328)(7193020); SRVR:DB8PR04MB7051; x-ms-traffictypediagnostic: DB8PR04MB7051:|DB8PR04MB7051: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:5797; x-forefront-prvs: 016572D96D x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(136003)(396003)(346002)(39860400002)(366004)(376002)(199004)(189003)(44832011)(229853002)(71200400001)(71190400001)(186003)(7696005)(76176011)(2501003)(99286004)(54906003)(6436002)(478600001)(8936002)(6116002)(3846002)(8676002)(81166006)(81156014)(14454004)(7736002)(2906002)(86362001)(316002)(26005)(102836004)(305945005)(5660300002)(33656002)(9686003)(55016002)(74316002)(5640700003)(4326008)(2351001)(6916009)(66946007)(76116006)(66446008)(66066001)(14444005)(256004)(64756008)(66556008)(66476007)(11346002)(486006)(446003)(6506007)(6246003)(25786009)(52536014)(476003); DIR:OUT; SFP:1101; SCL:1; SRVR:DB8PR04MB7051; H:DB8PR04MB6635.eurprd04.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: vO2/z63f2guE8NZuCLlts9o26bJQbTrou1batjYYLFmEuskxBIbkWKsg7eiTYvljC2rrGLzEG5covehnInIMUKT1WXRLBKeM/0w3Ognb+QqnSVlEWu7q5r0sreuBo0VwL62GHQhvEde8GMZ7nzpD4t4HvobIrps1jRzvrtUEEVT/VHzz1Tw/w71J8gGkeh8/YUwvAaWDrNJeYydPxrNoSjFQezQBkTzBxlczO2xwrVlBHtomKPwwZLD9cMUET2Cd95mhVnZXdjXFhRNWFdemGkqouJ4oVrlhX6DIpqDnZuxAu0WR88TADLHUhG7s8IL/TOp9DEbl/ddOzAXpcaKJZHX7qrUvHeJeiGpCSWqVVkGa9INhfQnKBOnS0y0/r+fu/bv3wpPyBv2fz3waL0sqaGkwCA3U7As1/W6ONcT4zC0= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4d95a0f0-7c34-4156-e146-08d73d148c6e X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Sep 2019 15:17:56.0391 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: weSaLee5cnBVm/fQNdWsZTyJ/DJtlykQPtMMQe+OuojfkFubRL42BJAfQsXg5l4GNMH+oA38/DHf+cGw2ujp5g== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8PR04MB7051 Subject: Re: [dpdk-dev] [PATCH v3 3/3] examples/ipsec-secgw: support IPv6 tunnel for lookaside proto 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" Hi Konstantin, Could you please review this patch. Thanks, Akhil >=20 > IPv6 tunnels are already supported in case of inline and > lookaside none cases. In case of protocol offload, the details > for IPv6 header need to be added in session configuration > for security session create. >=20 > Signed-off-by: Akhil Goyal > --- > examples/ipsec-secgw/ipsec.c | 14 +++++++++++++- > 1 file changed, 13 insertions(+), 1 deletion(-) >=20 > diff --git a/examples/ipsec-secgw/ipsec.c b/examples/ipsec-secgw/ipsec.c > index dc85adfe5..317faed7a 100644 > --- a/examples/ipsec-secgw/ipsec.c > +++ b/examples/ipsec-secgw/ipsec.c > @@ -33,8 +33,20 @@ set_ipsec_conf(struct ipsec_sa *sa, struct > rte_security_ipsec_xform *ipsec) >=20 > memcpy((uint8_t *)&tunnel->ipv4.dst_ip, > (uint8_t *)&sa->dst.ip.ip4, 4); > + } else if (IS_IP6_TUNNEL(sa->flags)) { > + tunnel->type =3D > + RTE_SECURITY_IPSEC_TUNNEL_IPV6; > + tunnel->ipv6.hlimit =3D IPDEFTTL; > + tunnel->ipv6.dscp =3D 0; > + tunnel->ipv6.flabel =3D 0; > + > + memcpy((uint8_t *)&tunnel->ipv6.src_addr, > + (uint8_t *)&sa->src.ip.ip6.ip6_b, 16); > + > + memcpy((uint8_t *)&tunnel->ipv6.dst_addr, > + (uint8_t *)&sa->dst.ip.ip6.ip6_b, 16); > } > - /* TODO support for Transport and IPV6 tunnel */ > + /* TODO support for Transport */ > } > ipsec->esn_soft_limit =3D IPSEC_OFFLOAD_ESN_SOFTLIMIT; > } > -- > 2.17.1