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 3AA39A2EFC for ; Mon, 14 Oct 2019 05:39:18 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 4CE7E1C12C; Mon, 14 Oct 2019 05:39:16 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by dpdk.org (Postfix) with ESMTP id E43181C12A for ; Mon, 14 Oct 2019 05:39:13 +0200 (CEST) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id x9E3ZMZN008459; Sun, 13 Oct 2019 20:39:12 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : references : in-reply-to : content-type : content-transfer-encoding : mime-version; s=pfpt0818; bh=kLyRfAbGn+7ft7XCevp3KTmQw+rhU63CgRjliZUxwuo=; b=wg6LzBT/IEvPMuWNo95Ite/NBUHy9mgfzBm+W3PSYXGhi7OrQRHWQjmK7ZXdYxB8Q9Uj M2iHSZxIzAtCHq6Bi/noJs7s18H5UPFaFHyvkw5xw9G08JLnxc9rdC9l9sG7r75CvlAK O8lZRSdlSF76oWh/3vqo2cZl9mjMYy20537F39WjAfgUidnAqgyIX/O/FmJxchzkoVRm l3UeXWQjj8G4vqB5kd3PADMKKBuV1j/zRT9zyXj6IqxDkUBs+tQqPRRvYRKEaxTYSIvz Zhjjd/YxNO7gpgHP7Pu9e315eD1hp44phsLzDovGjR1kRZfDsyfyS2Pa4u1ZQv1mwEzr 7Q== Received: from sc-exch03.marvell.com ([199.233.58.183]) by mx0b-0016f401.pphosted.com with ESMTP id 2vkebnvbrx-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Sun, 13 Oct 2019 20:39:12 -0700 Received: from SC-EXCH04.marvell.com (10.93.176.84) by SC-EXCH03.marvell.com (10.93.176.83) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Sun, 13 Oct 2019 20:39:11 -0700 Received: from NAM04-CO1-obe.outbound.protection.outlook.com (104.47.45.51) by SC-EXCH04.marvell.com (10.93.176.84) with Microsoft SMTP Server (TLS) id 15.0.1367.3 via Frontend Transport; Sun, 13 Oct 2019 20:39:11 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CwJ+A13/K8Oq3k105YggaTxYxffJ61n6oEHBzzJ5HAckv6/cXf6f99KCLg4jyMgddZFpZkJEGUBpiD4rqFj+Ooc3AJoODEAHKxgZE/4SaN7JNP15dzrrCSmLKOvq1gUzsNy2fW/+AeFxWBOalrDibt/Un0RDpwFYk8eymP1OUv7vkvGSepClKBxWSTZYstT+826Yq2DUx8dDW/Eex/pS7PIvLbqeSURh7PMxAq+k2Amr9ySlYv1vht7JEuyaS1EM6FVRy3a4K6u56rzqV6HGlvjJioD/srcwxHw0sDzYEuerjuREDm5ahmlUv07Ba7a4VrYc2lc41I+ioiRwMTDinQ== 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=kLyRfAbGn+7ft7XCevp3KTmQw+rhU63CgRjliZUxwuo=; b=MRA/ob8a/zamuC/GTYRkpFy21qzg7eZkwqsARVaZyTyuwbeFuuxQOICisriH7ElNQ9j8WMKHdzD9bE62CRqnQeqTuZNL8D0DWGhF00nKQz+BMbnzE9DgOBYMHcY93idJEDchJclI/VO+dSrRp2/K5lP1DXnsDtnGvsYJuUTwzRgtEqoKeRMVXagGUzDsd30V+EqG3VeUWNfYZDKs7x6DV9fQpt/x3BjgpVjxOPmiWJLBoaWmLo6MgXxZPvR5bwf2ARNkrUP3cBV9l7vCUeJTZWuvgISwBig5/XfNAk8vFga6bvBjPHkkkbYHb7k1858HZE9cDvCYXIrIqEWGPxos4A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=marvell.com; dmarc=pass action=none header.from=marvell.com; dkim=pass header.d=marvell.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.onmicrosoft.com; s=selector2-marvell-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=kLyRfAbGn+7ft7XCevp3KTmQw+rhU63CgRjliZUxwuo=; b=SxJH4oq2ZcTkSROL4hDdNzumvwbyMDE1exVaVLETt8EjCwEWBlI/Yt8WHR1WkkGavUh471dd+ILdTGoWXKivNtflsgKhP20JNN5w6/Cj4H0bPyS9i1fs3URw/j/V29wXxeNQinj4QWRa8VaJXpBsrX2Vdljd+gHZ3myUv15rxx0= Received: from MN2PR18MB2877.namprd18.prod.outlook.com (20.179.20.218) by MN2PR18MB3085.namprd18.prod.outlook.com (20.179.21.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2347.21; Mon, 14 Oct 2019 03:39:09 +0000 Received: from MN2PR18MB2877.namprd18.prod.outlook.com ([fe80::6d15:3367:4c9:5385]) by MN2PR18MB2877.namprd18.prod.outlook.com ([fe80::6d15:3367:4c9:5385%7]) with mapi id 15.20.2347.021; Mon, 14 Oct 2019 03:39:09 +0000 From: Anoob Joseph To: Arek Kusztal , "dev@dpdk.org" CC: "akhil.goyal@nxp.com" , "fiona.trahe@intel.com" , Shally Verma Thread-Topic: [EXT] [PATCH v5] cryptodev: extend api of asymmetric crypto by session-less Thread-Index: AQHVf1qn4fNUq5SyxEeoS8ZXO0UMdqdZgW9g Date: Mon, 14 Oct 2019 03:39:09 +0000 Message-ID: References: <20191010110239.10508-1-arkadiuszx.kusztal@intel.com> In-Reply-To: <20191010110239.10508-1-arkadiuszx.kusztal@intel.com> Accept-Language: en-IN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [115.113.156.2] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: bfba483f-80a3-4e0c-1032-08d750581277 x-ms-traffictypediagnostic: MN2PR18MB3085: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:1923; x-forefront-prvs: 01901B3451 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(376002)(39850400004)(346002)(136003)(366004)(396003)(189003)(199004)(13464003)(66446008)(74316002)(2501003)(71200400001)(7736002)(305945005)(8676002)(99286004)(71190400001)(110136005)(66946007)(81156014)(81166006)(54906003)(2906002)(256004)(64756008)(6116002)(66556008)(3846002)(66476007)(8936002)(76116006)(7696005)(76176011)(52536014)(86362001)(55016002)(25786009)(6246003)(107886003)(316002)(478600001)(14454004)(6436002)(102836004)(446003)(476003)(11346002)(4326008)(486006)(9686003)(33656002)(53546011)(6506007)(5660300002)(55236004)(66066001)(186003)(26005)(229853002); DIR:OUT; SFP:1101; SCL:1; SRVR:MN2PR18MB3085; H:MN2PR18MB2877.namprd18.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: marvell.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: DrzcAg9ClBOIRvxmIXEXMWwSYhJo+MCXW1LZZZ3JYsP3JeVpntTCTSxN4ha8j4T9MumVdTLGBbZo2baPBvmF4DTODB0cR9icBBJwUZBYdgDVtpE5rrTjLTuQ4jYAjeUrwLTuzKkMF/JGMnVnjvHn/4lF0N/noAaWSfl5bUZRlJHcE+P+6mcjeL8xXyBGzrr5/u28usfPqQO0KfpFpaflQtyZ33sRimVaYfzufBxgiDibJXYT9N1yx7CzYrad8UCh1K9inQX8z5mapI/elm2uROQKYUpjkh4fr+p+dMyBhiLcmX9TAKYR4dl7gmsllEclz98t5qqA3Y4teo9D11+MQppvOPpVOqrlQx5bEXKyg3XGm5lvU1Y8H00OQuXixhz1pa2fNmzY+FfUyvKZaRhyZcifMhh9q/b/l7fdV9CtjGw= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: bfba483f-80a3-4e0c-1032-08d750581277 X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Oct 2019 03:39:09.1992 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 70e1fb47-1155-421d-87fc-2e58f638b6e0 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: b/JdeyytWL9FJdjZg1DUct1kPnkjFNBxwKIU0lgPw0j1Do1Y0p9WbI6CBMfESrfFlE1iWsIW7wD1sej9tJ3CPg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR18MB3085 X-OriginatorOrg: marvell.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.95,1.0.8 definitions=2019-10-14_03:2019-10-10,2019-10-14 signatures=0 Subject: Re: [dpdk-dev] [EXT] [PATCH v5] cryptodev: extend api of asymmetric crypto by session-less 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 Arek, Minor suggestion inline. Not a blocker issue. Acked-by: Anoob Joseph > -----Original Message----- > From: Arek Kusztal > Sent: Thursday, October 10, 2019 4:33 PM > To: dev@dpdk.org > Cc: akhil.goyal@nxp.com; fiona.trahe@intel.com; Anoob Joseph > ; Shally Verma ; Arek Kusztal > > Subject: [EXT] [PATCH v5] cryptodev: extend api of asymmetric crypto by > session-less >=20 > External Email >=20 > ---------------------------------------------------------------------- > This commit adds asymmetric session-less option to rte_crypto_asym_op. > Feature flag for session-less is added to rte_cryptodev. >=20 > Signed-off-by: Arek Kusztal > --- > v2: > - added union > v3: > - added entry into feature matrix > - added information to prog_guide > v4: > - fixed formatting > - fixed grammar > v5: > - added release note >=20 > doc/guides/cryptodevs/features/default.ini | 1 + > doc/guides/prog_guide/cryptodev_lib.rst | 9 ++++++++- > doc/guides/rel_notes/release_19_11.rst | 5 +++++ > lib/librte_cryptodev/rte_crypto_asym.h | 9 +++++++-- > lib/librte_cryptodev/rte_cryptodev.h | 2 ++ > 5 files changed, 23 insertions(+), 3 deletions(-) >=20 > diff --git a/doc/guides/cryptodevs/features/default.ini > b/doc/guides/cryptodevs/features/default.ini > index d3ee1af..b7f9a0a 100644 > --- a/doc/guides/cryptodevs/features/default.ini > +++ b/doc/guides/cryptodevs/features/default.ini > @@ -26,6 +26,7 @@ OOP LB In LB Out =3D > RSA PRIV OP KEY EXP =3D > RSA PRIV OP KEY QT =3D > Digest encrypted =3D > +Asymmetric sessionless =3D >=20 > ; > ; Supported crypto algorithms of a default crypto driver. > diff --git a/doc/guides/prog_guide/cryptodev_lib.rst > b/doc/guides/prog_guide/cryptodev_lib.rst > index 9719944..d420220 100644 > --- a/doc/guides/prog_guide/cryptodev_lib.rst > +++ b/doc/guides/prog_guide/cryptodev_lib.rst > @@ -876,7 +876,14 @@ private asymmetric session data. Once this is done, > session should be freed usin >=20 > Asymmetric Sessionless Support > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > -Currently asymmetric crypto framework does not support sessionless. > +Asymmetric crypto framework supports session-less operations. > + > +Fields that should be set by user are: > + > +Member xform of struct rte_crypto_asym_op should point to the user > created rte_crypto_asym_xform. > +Note that this rte_crypto_asym_xform should be immutable for the > lifetime of associated crypto_op. > + > +Member sess_type of rte_crypto_op should be set to > RTE_CRYPTO_OP_SESSIONLESS. >=20 > Transforms and Transform Chaining > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > diff --git a/doc/guides/rel_notes/release_19_11.rst > b/doc/guides/rel_notes/release_19_11.rst > index 02fc8fb..4ede7e8 100644 > --- a/doc/guides/rel_notes/release_19_11.rst > +++ b/doc/guides/rel_notes/release_19_11.rst > @@ -85,6 +85,11 @@ New Features > Added stateful decompression support in the Intel QuickAssist Technolo= gy > PMD. > Please note that stateful compression is not supported. >=20 > +* **Added cryptodev API to use asymmetric session-less operation.** > + > + Added session-less option to cryptodev asymmetric API. It works the > + same way as symmetric crypto does namely xform is used directly by the > crypto op. > + [Anoob] The above line could be confusing. I guess you will need a comma af= ter "crypto does". It works the same way as symmetric crypto does, namely xform is used direct= ly by the crypto op. [Even "does" may not be required] =20 >=20 > Removed Items > ------------- > diff --git a/lib/librte_cryptodev/rte_crypto_asym.h > b/lib/librte_cryptodev/rte_crypto_asym.h > index 4fbef2f..0d34ce8 100644 > --- a/lib/librte_cryptodev/rte_crypto_asym.h > +++ b/lib/librte_cryptodev/rte_crypto_asym.h > @@ -522,8 +522,13 @@ struct rte_crypto_dsa_op_param { > * > */ > struct rte_crypto_asym_op { > - struct rte_cryptodev_asym_session *session; > - /**< Handle for the initialised session context */ > + RTE_STD_C11 > + union { > + struct rte_cryptodev_asym_session *session; > + /**< Handle for the initialised session context */ > + struct rte_crypto_asym_xform *xform; > + /**< Session-less API crypto operation parameters */ > + }; >=20 > __extension__ > union { > diff --git a/lib/librte_cryptodev/rte_cryptodev.h > b/lib/librte_cryptodev/rte_cryptodev.h > index e175b83..c6ffa3b 100644 > --- a/lib/librte_cryptodev/rte_cryptodev.h > +++ b/lib/librte_cryptodev/rte_cryptodev.h > @@ -448,6 +448,8 @@ rte_cryptodev_asym_get_xform_enum(enum > rte_crypto_asym_xform_type *xform_enum, /**< Support RSA Private Key > OP with CRT (quintuple) Keys */ > #define RTE_CRYPTODEV_FF_DIGEST_ENCRYPTED (1ULL << 19) > /**< Support encrypted-digest operations where digest is appended to dat= a > */ > +#define RTE_CRYPTODEV_FF_ASYM_SESSIONLESS (1ULL << 20) > +/**< Support asymmetric session-less operations */ >=20 >=20 > /** > -- > 2.1.0