From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id AC5F8A054D; Thu, 26 May 2022 13:06:30 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 95C7940151; Thu, 26 May 2022 13:06:30 +0200 (CEST) Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id 604D840150 for ; Thu, 26 May 2022 13:06:28 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1653563188; x=1685099188; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=CTrH3cpQyxKfMsNS2o0BLyaNdFO3FPZc/OsQdahMqDY=; b=IlnTBCl25kl/pbw1fsrzk4+yO/WdVom/PPguBR2MtRYwlCHxsES/gI7N JD9XIRHNGm8FeVkzsD4z2UXVrnPuP2nBGsK3U1HOqnfeRox/yBG7LK7DS EFVqvEopkenCff7bI4kUCYJn6sTcmsFOvJ/XgdXwfups3EsRGdO71j6Ta atP6qy+pk+kc840SZFkXq8Ax9Hqgx5i7kIM65QOVBw5Kt71wHsMz2I+at rS8YvCgj6YynnQiqJtglm2PSh8PPAvbf7xd3MWoJIm5Erpsx/Zix9+x6e 8wmf1Jp5/NgRXbKrwOwk+lDjIF8cGNthXU5ZIVf3XuM0ttDlzQ5eSNbdb w==; X-IronPort-AV: E=McAfee;i="6400,9594,10358"; a="334762408" X-IronPort-AV: E=Sophos;i="5.91,252,1647327600"; d="scan'208";a="334762408" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 May 2022 04:06:27 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.91,252,1647327600"; d="scan'208";a="821207312" Received: from orsmsx606.amr.corp.intel.com ([10.22.229.19]) by fmsmga006.fm.intel.com with ESMTP; 26 May 2022 04:06:26 -0700 Received: from orsmsx611.amr.corp.intel.com (10.22.229.24) by ORSMSX606.amr.corp.intel.com (10.22.229.19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Thu, 26 May 2022 04:06:26 -0700 Received: from orsmsx605.amr.corp.intel.com (10.22.229.18) by ORSMSX611.amr.corp.intel.com (10.22.229.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Thu, 26 May 2022 04:06:26 -0700 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx605.amr.corp.intel.com (10.22.229.18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27 via Frontend Transport; Thu, 26 May 2022 04:06:26 -0700 Received: from NAM12-MW2-obe.outbound.protection.outlook.com (104.47.66.45) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.27; Thu, 26 May 2022 04:06:25 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oahiQ7hqFQ40kwgAgi4buk/crodIE/NJgRj67xodNWTIl3AgxG3InZkO8zJQCH2mL0vHLM4vxg9uvsu+YXH8nMDnWag74fKu6y/ns5m4GfUMFp7seKRtCV450+Ddw5MqdARx2xw2AKD776S4k4ri+6qd+dh+IEM84FzBRtOD6mjsIOphjBRnbAv5jAPiRy4gdH0U2D0UYPSnWwiheQLxVpu387Bx4e/vFzGZ4NFZQwx5lau2H9GhRr3xMA0bLfR8L55JTaTL7G92nioTk4nW9Ats326dSgL/V+S9ppX1ExbW1X3WAvm449EiRf88g519+X3EJLpHcvyr9ZO+MaYYTw== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=z6ms8KU5BeR5BwNEZjePI6/2Q1HOC2gMghrBLlvyV+c=; b=UI14kZEA37CMdMon+JQcr8zQl1ic/OkPKidyo6LpPCvlQrzhV30W2p+v6hsFEx/lSMOfJWHp4MqdzGjhcaN2ujdOUrWIBzLqxjQcpLkp084gIHYNt655/lhfrLUeGQNZ/ewmCBcU8t5sOqr6TNzGPo0IJmdl0L2m6FMR/wvW0y/9N6JBm/yRIneLKUBT+6U1c90UBy+HAx7/tF09C0q/mJ5mw2txOnf1p+sRjKsuMTxHKcCvEonF9Tlgudd9eOFLCejq00FPCHB4Tabht/JpdBM9PiXnY8j7wWM8x5gEmXqxi0+D7wgZACYIJ0ZPUzknYCe1HGYhRYLi/5yvc5Evpg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from PH0PR11MB5013.namprd11.prod.outlook.com (2603:10b6:510:30::21) by DM5PR1101MB2123.namprd11.prod.outlook.com (2603:10b6:4:53::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5293.13; Thu, 26 May 2022 11:06:24 +0000 Received: from PH0PR11MB5013.namprd11.prod.outlook.com ([fe80::c1de:722f:b4f3:91b5]) by PH0PR11MB5013.namprd11.prod.outlook.com ([fe80::c1de:722f:b4f3:91b5%3]) with mapi id 15.20.5293.013; Thu, 26 May 2022 11:06:24 +0000 From: "Kusztal, ArkadiuszX" To: Akhil Goyal , "dev@dpdk.org" CC: "Zhang, Roy Fan" Subject: RE: [EXT] [PATCH v2 03/14] cryptodev: separate key exchange operation enum Thread-Topic: [EXT] [PATCH v2 03/14] cryptodev: separate key exchange operation enum Thread-Index: AQHYcFkdc+XOiQI0KUmAWXQm5r7joq0w/huAgAABU2A= Date: Thu, 26 May 2022 11:06:24 +0000 Message-ID: References: <20220525155324.9288-1-arkadiuszx.kusztal@intel.com> <20220525155324.9288-4-arkadiuszx.kusztal@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-reaction: no-action dlp-version: 11.6.500.17 dlp-product: dlpe-windows authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: f5c759df-c304-440f-b88f-08da3f07c5cc x-ms-traffictypediagnostic: DM5PR1101MB2123:EE_ x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: FBu1Ic6JdE3sess4YO2nO3cDKXR2gRM5ApXPbKMpNz+uWApZxm6fxsctn90D+l1a1GXuweDNMFFVgxKwn19bBO/lA2bFFtjzD4cYIs+L3L2apjCbzaxiO5sf0v6ZSj+q5WzjolVc3iTGr7jKo+BWoVyUUhojVACGIoSAinRNuRyQPxzho5upWgyULyGsBLDQ4erGxiizihgv+SyWN4u+QyJLwlilPdcBhknDSQUiOREsF5zHSoPUXc5EV745B7Bh3s/p5a/q2EKQZCEMc0veHyqCxqIVa+BbiVcx92HcvwPpgBtnCYgpG3HFNygBiHqOpv8aHVAryHKj3/6hpBUmuNFIM0xbicaUVqIWHzRnR3urn0Cisa4TsZS/AYEbThcWvZVliehkeDuTEO/giLBd4eA1PCHnQ1aZqGxS6OEpTzFEBnQV65RuEm97xCYxI9dW1nwjsGGlPc8YdmBYKZFOVvG41I/WkdK/6ervzPdxFoVQ5x08dH6TBPlw9039vQXngHUOiUHy1RgC3rprLVbcZw1EzxeXUI/Ddv250EEsiC3zErOd7ntYhEtYgA6XTtpjXEgrBvV7N2w8chTMhmZxPEsqSa1mSnFD2btsCSyiBDCfqVJZbjuSlyi9NoJ8lcAZQIQBt4ZHp9+K7QS8vHOvr3GlTKTB/Ko3Q3hDhlx9eM0JkomgtI8GbAbUXAjL/7HO9rNd8f1OJb3miCCrRb8mHA== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PH0PR11MB5013.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(366004)(71200400001)(33656002)(8936002)(26005)(52536014)(5660300002)(508600001)(53546011)(9686003)(6506007)(66556008)(66446008)(86362001)(64756008)(4326008)(8676002)(66476007)(66946007)(2906002)(7696005)(38070700005)(122000001)(55016003)(38100700002)(82960400001)(110136005)(76116006)(107886003)(186003)(83380400001)(316002); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?E8Z2g9Abuhhfngwo6Skr2DLbY80eReI51zYnynUptTvWoA1D2tatkjjJW1/a?= =?us-ascii?Q?4q0vuzXII42uXIp2/Npvr3Y8pUyoZJLB4CMQDWagwTDGVpw40T2DwHufSXW9?= =?us-ascii?Q?D14tV1pk1nHgqfj7UMSFUXFVFIvzmor7suBfStfG5r6o8jEm6gJYOMn/5t+V?= =?us-ascii?Q?yEc7SGcsMLM+0p4G+L8EVlHWkhb6UQJZF7ibFB1n3hS+8o2qtMfKePA9NAl0?= =?us-ascii?Q?Z3gEyq6LFg9VWfXgzBVanJ/BkQO6YYKv20L76eV/E1YxvatzsbTIbDMc87so?= =?us-ascii?Q?JcJKS4QcN4Qk1/W+TBX8xQkCUlKgpkysj8ZPv3lMJpuxytdVDMS5T3kMXSrc?= =?us-ascii?Q?7iqDZT/oiWsQOnb1nmfIDe6dwvvhNFXuEQlFFLEwbf5RuU/IqhbU7xBh3AxF?= =?us-ascii?Q?G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hdjwiJN4eBQJ?= =?us-ascii?Q?Plsn8LaAiVjsLb5GL5qIRuK4PEPtA6uVU51SaXVQ4GQWpKlmdtgLvx636v1M?= =?us-ascii?Q?hDQjraLiiIl78kOjtE9XUzGS5t3HmV9mE3XVfMOPwVlg5it1uz++/qS/YV5G?= =?us-ascii?Q?lRrR7LjwLxm1rQF9IMN/W1Jt3riJd0gO4A59jUVaNgjq8Yrr653dP1E/Odxg?= =?us-ascii?Q?JlAfM8cTE0cXHT8W93FOcn4ugUI5dIg1ITFygejKqHtRK2iisjz9XSwB1FcE?= =?us-ascii?Q?l+Vbi2lfl38/fT7GkVFstCVqQKrxpYzXLHoK4d32/LVOYb95FoBPx0I8MKdT?= =?us-ascii?Q?mfi6fpBjnijcJVlIRj6Lr3Lj53oMTSSSCSx+wPhmnMVF15jzT1nn8CGxZPu8?= =?us-ascii?Q?Zv5jy/lwUOWEkwvrxijzYU0wDD81900Sc6ag97nPzgqeuKdOivTFXZnFtlVB?= =?us-ascii?Q?0Mw0f8OX0UPy/45R8tXVmNoU93RX4EY=3D?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: PH0PR11MB5013.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: f5c759df-c304-440f-b88f-08da3f07c5cc X-MS-Exchange-CrossTenant-originalarrivaltime: 26 May 2022 11:06:24.2039 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: AU9FXO3RrKxfvkIs5T0chPY4SPeu1133R67elGDQaC/t+fe1EXfOwXTLc7iPWsT5NLAZoli0uZaPJAr0lvqxyWyuUAht7bo0q5uZoNwZqU8= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR1101MB2123 X-OriginatorOrg: intel.com X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org > -----Original Message----- > From: Akhil Goyal > Sent: Thursday, May 26, 2022 12:58 PM > To: Kusztal, ArkadiuszX ; dev@dpdk.org > Cc: Zhang, Roy Fan > Subject: RE: [EXT] [PATCH v2 03/14] cryptodev: separate key exchange > operation enum >=20 > > /** > > + * Asymmetric crypto key exchange operation type */ enum > > +rte_crypto_asym_ke_type { > > + RTE_CRYPTO_ASYM_KE_PRIVATE_KEY_GENERATE, >=20 > Is it better to shorten it to > RTE_CRYPTO_ASYM_KE_PRIV_KEY_GENERATE > RTE_CRYPTO_ASYM_KE_PUB_KEY_GENERATE +1, Actually I am not big fan of having asym everywhere too. RTE_CRYPTO_KE_PRIV_KEY_GENERATE would be equally good. >=20 > > + /**< Private Key generation operation */ > > + RTE_CRYPTO_ASYM_KE_PUBLIC_KEY_GENERATE, > > + /**< Public Key generation operation */ > > + RTE_CRYPTO_ASYM_KE_SHARED_SECRET_COMPUTE > > + /**< Shared Secret compute operation */ }; > > + > > +/** > > * Padding types for RSA signature. > > */ > > enum rte_crypto_rsa_padding_type { > > @@ -238,7 +248,7 @@ struct rte_crypto_modinv_xform { > > * > > */ > > struct rte_crypto_dh_xform { > > - enum rte_crypto_asym_op_type type; > > + enum rte_crypto_asym_ke_type type; > > /**< Setup xform for key generate or shared secret compute */ > > rte_crypto_uint p; > > /**< Prime modulus data */ > > @@ -375,26 +385,27 @@ struct rte_crypto_rsa_op_param { struct > > rte_crypto_dh_op_param { > > rte_crypto_uint pub_key; > > /**< > > - * Output generated public key when xform type is > > - * DH PUB_KEY_GENERATION. > > - * Input peer public key when xform type is DH > > - * SHARED_SECRET_COMPUTATION > > + * Output - generated public key, when xform type is >=20 > It is not xform type, Right? > It should be key exchange type. Yes, I meant xform op_type. Will change, leter it will be overwritten by mo= ve dh op patch too. > Check at other places also. >=20 > > + * RTE_CRYPTO_ASYM_KE_PUBLIC_KEY_GENERATE. > > * > > + * Input - peer's public key, when xform type is > > + * RTE_CRYPTO_ASYM_KE_SHARED_SECRET_COMPUTE. > > */ > > > > rte_crypto_uint priv_key; > > /**< > > - * Output generated private key if xform type is > > - * DH PRIVATE_KEY_GENERATION > > - * Input when xform type is DH SHARED_SECRET_COMPUTATION. > > + * Output - generated private key, when xform type is > > + * RTE_CRYPTO_ASYM_KE_PRIVATE_KEY_GENERATE. > > * > > + * Input - private key, when xform type is one of: > > + * RTE_CRYPTO_ASYM_KE_PUBLIC_KEY_GENERATE, > > + * RTE_CRYPTO_ASYM_KE_SHARED_SECRET_COMPUTE. > > */ > > > > rte_crypto_uint shared_secret; > > /**< > > - * Output with calculated shared secret > > - * when dh xform set up with op type =3D > > SHARED_SECRET_COMPUTATION. > > - * > > + * Output - calculated shared secret when xform type is > > + * RTE_CRYPTO_ASYM_KE_SHARED_SECRET_COMPUTE. > > */ > > }; > >