From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by dpdk.org (Postfix) with ESMTP id DB9585B26 for ; Wed, 6 Feb 2019 06:07:50 +0100 (CET) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x1650B4w020207; Tue, 5 Feb 2019 21:07:48 -0800 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=fGUhL5k5EaxSLhbiQp4lwIuJGK/EhGxOPSmSgmNyzHA=; b=hHDQ8S3tPcEH8IJ75as21HcoYZpu5OA399755scbpy5XnVkxg/I4A8Daog/zXHrf+zGc onlCfj14MdJq2FhKoXDDJSFD3VxI0cxnZZjqS8W2wbKdAdrUvelge9/i6Sz0d4+K5JU+ uR29W215r6+x8wly+zGhItL0IEKZq+IAo4gbnwxO/yXWH6U8pF7GuyitcNJr4ecA+Q1f XYM33X4/S++fZr8RjsSTB+vM/wjcEgkTzV/ZZH6wAFg6CHxpl+jrqq3LUm2raVIs3SVK fY39fFIxf5o1QM8G5Vm9E/6ykfsryjnl1sSez8MsuIPHNaf5iQJNtmnBFtqSPKHZQC5H uQ== Received: from sc-exch03.marvell.com ([199.233.58.183]) by mx0a-0016f401.pphosted.com with ESMTP id 2qfc2atr8e-3 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Tue, 05 Feb 2019 21:07:47 -0800 Received: from SC-EXCH03.marvell.com (10.93.176.83) by SC-EXCH03.marvell.com (10.93.176.83) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Tue, 5 Feb 2019 21:07:46 -0800 Received: from NAM05-DM3-obe.outbound.protection.outlook.com (104.47.49.56) by SC-EXCH03.marvell.com (10.93.176.83) with Microsoft SMTP Server (TLS) id 15.0.1367.3 via Frontend Transport; Tue, 5 Feb 2019 21:07:46 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.onmicrosoft.com; s=selector1-marvell-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fGUhL5k5EaxSLhbiQp4lwIuJGK/EhGxOPSmSgmNyzHA=; b=eKg5fct88rFJ8e3sDvUHCW2EnHSk0y3JewXeqZXcmYC4zAY7NUBE2VkHlsvI1eDWo+XIFWIWAU2dkhR7eMVnBSON8FrxRFn0pF2Au6jTg2IUf4+uf11yAcZIzAdiQCHxIpqI/+l4B2goqeJnigC5NZ7hX11YB/dX1NgREzqX5HE= Received: from BN6PR1801MB2052.namprd18.prod.outlook.com (10.161.157.11) by BN6PR1801MB1985.namprd18.prod.outlook.com (10.161.154.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1580.22; Wed, 6 Feb 2019 05:07:42 +0000 Received: from BN6PR1801MB2052.namprd18.prod.outlook.com ([fe80::9403:ace8:3dc7:355]) by BN6PR1801MB2052.namprd18.prod.outlook.com ([fe80::9403:ace8:3dc7:355%5]) with mapi id 15.20.1601.016; Wed, 6 Feb 2019 05:07:42 +0000 From: Shally Verma To: Arek Kusztal , "dev@dpdk.org" CC: "akhil.goyal@nxp.com" , "fiona.trahe@intel.com" , "sunila.sahu@caviumnetworks.com" , "ashish.gupta@caviumnetworks.com" , "umesh.kartha@caviumnetworks.com" Thread-Topic: [PATCH v2] cryptodev: rework mod exp and mod inv comments Thread-Index: AQHUvX9878posf0A2U+FPkA8IrDLOKXSNecQ Date: Wed, 6 Feb 2019 05:07:41 +0000 Message-ID: References: <20190205181941.10484-1-arkadiuszx.kusztal@intel.com> In-Reply-To: <20190205181941.10484-1-arkadiuszx.kusztal@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [115.113.156.3] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; BN6PR1801MB1985; 20:wCxxN0jzl9nZNtR5I/69sIHN04I9GzKWkSu7wyT8ZdzvAe7KIx96GERMlBbUild4rsG/8327rYNC3u6ybxQeK/S/JutHcaxNNXXSMlvtHQHOOMGpwQN7wbAPjpmRw2bc27C7Mj156uT4LzBFl6truLqxBxAUiAZMrfG1BG+Q6GQ= x-ms-office365-filtering-correlation-id: 36877a36-6685-457a-c1fc-08d68bf105d8 x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(7168020)(4627221)(201703031133081)(201702281549075)(8990200)(5600110)(711020)(4605077)(2017052603328)(7153060)(7193020); SRVR:BN6PR1801MB1985; x-ms-traffictypediagnostic: BN6PR1801MB1985: x-microsoft-antispam-prvs: x-forefront-prvs: 0940A19703 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(136003)(366004)(346002)(39860400002)(396003)(376002)(13464003)(199004)(189003)(106356001)(486006)(105586002)(8936002)(3846002)(4326008)(71190400001)(71200400001)(6116002)(2906002)(6246003)(478600001)(33656002)(14454004)(66066001)(6436002)(102836004)(9686003)(8676002)(74316002)(54906003)(316002)(6506007)(256004)(7736002)(14444005)(11346002)(446003)(81156014)(305945005)(25786009)(55016002)(476003)(68736007)(81166006)(76176011)(229853002)(7696005)(53936002)(99286004)(110136005)(2501003)(86362001)(26005)(55236004)(97736004)(186003); DIR:OUT; SFP:1101; SCL:1; SRVR:BN6PR1801MB1985; H:BN6PR1801MB2052.namprd18.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: marvell.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: l1G62e/h+2WVe54QPpD9d3j6WhTa1EIN0MSLWTGXrOdqbeqKn0drr3HqCI7r+8/5LA3Ix1pd3CXAdWDN04dE1ZKFFRhah7wfI89/SgEzNyaJNqi+DzriPKp9kra8Yn6kberSj21ygNmF9RxUzlk5wGxy1dcZtBZTQ8n27qHoALylizKPLXiJQhSEWsL1ftXHa/KiBKj/89x86Ls9bC24QCmKGDU+ik2nJbqGXX04vl5rd4U/u/Ofo7w+D1qF53Kzjmyj/CoumDJ54vDrZTyR4brawE8VUD0prrZgx0LMVi3JNPPx6nUpl7jg0oXjIi7un/RlexdwuzcD1WuGIbq3QaBpws5iWm03dVxjAy10hBAWXBsqvs72FZMMEULeODVRIFAVOIi063rD9Sa31Yswpp5n/opXIS4HP9CR0f5Qa5k= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 36877a36-6685-457a-c1fc-08d68bf105d8 X-MS-Exchange-CrossTenant-originalarrivaltime: 06 Feb 2019 05:07:41.9143 (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-Transport-CrossTenantHeadersStamped: BN6PR1801MB1985 X-OriginatorOrg: marvell.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-02-06_03:, , signatures=0 X-Proofpoint-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1011 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1902060038 Subject: Re: [dpdk-dev] [PATCH v2] cryptodev: rework mod exp and mod inv comments 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: , X-List-Received-Date: Wed, 06 Feb 2019 05:07:51 -0000 HI Arek, Acked with minor feedback. >-----Original Message----- >From: Arek Kusztal >Sent: 05 February 2019 23:50 >To: dev@dpdk.org >Cc: akhil.goyal@nxp.com; fiona.trahe@intel.com; shally.verma@caviumnetwork= s.com; sunila.sahu@caviumnetworks.com; >ashish.gupta@caviumnetworks.com; umesh.kartha@caviumnetworks.com; Arek Kus= ztal >Subject: [PATCH v2] cryptodev: rework mod exp and mod inv comments > >External Email > >This patch changes modular exponentiation and modular multiplicative >inverse API comments to make it more precise. > >Signed-off-by: Arek Kusztal >--- >v2: >- grammar fixes > > lib/librte_cryptodev/rte_crypto_asym.h | 44 ++++++++++++++++++++++-------= ----- > 1 file changed, 29 insertions(+), 15 deletions(-) > Acked-by: Shally Verma >diff --git a/lib/librte_cryptodev/rte_crypto_asym.h b/lib/librte_cryptodev= /rte_crypto_asym.h >index 5e185b2..9582ee3 100644 >--- a/lib/librte_cryptodev/rte_crypto_asym.h >+++ b/lib/librte_cryptodev/rte_crypto_asym.h >@@ -72,8 +72,8 @@ enum rte_crypto_asym_xform_type { > * Refer to rte_crypto_asym_op_type > */ > RTE_CRYPTO_ASYM_XFORM_MODINV, >- /**< Modular Inverse >- * Perform Modulus inverse b^(-1) mod n >+ /**< Modular Multiplicative Inverse >+ * Perform Modular Multiplicative Inverse b^(-1) mod n > */ > RTE_CRYPTO_ASYM_XFORM_MODEX, > /**< Modular Exponentiation >@@ -233,29 +233,39 @@ struct rte_crypto_rsa_xform { > struct rte_crypto_modex_xform { > rte_crypto_param modulus; > /**< modulus >- * Prime modulus of the modexp transform operation in octet-string >- * network byte order format. >+ * Pointer to the modulus data for modexp transform operation >+ * in octet-string network byte order format, any positive integer >+ * This statement looks incomplete. You can write it "it should be positive in= teger " but is it required to be mentioned? Coz input is array of uint8_t s= o assumption is it will be positive. ... > struct rte_crypto_modinv_xform { > rte_crypto_param modulus; > /**< >- * Pointer to the prime modulus data for modular >- * inverse operation in octet-string network byte >- * order format. >+ * Pointer to the modulus data for modular multiplicative inverse >+ * operation in octet-string network byte order format, >+ * positive integer Same comment as above. >+ * >+ * In case this number is equal to zero the driver shall set >+ * the crypto op status field to RTE_CRYPTO_OP_STATUS_ERROR >+ * >+ * This number shall be relatively prime to base >+ * in corresponding Modular Multiplicative Inverse >+ * rte_crypto_mod_op_param > */ > }; > >@@ -317,14 +327,18 @@ struct rte_crypto_dsa_xform { > ... >2.1.0