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 D19AC43C3B; Thu, 29 Feb 2024 17:32:36 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 49DEB41109; Thu, 29 Feb 2024 17:32:36 +0100 (CET) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by mails.dpdk.org (Postfix) with ESMTP id 399BE402B4 for ; Thu, 29 Feb 2024 17:32:35 +0100 (CET) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 41T83I9T022449; Thu, 29 Feb 2024 08:32:30 -0800 Received: from nam10-dm6-obe.outbound.protection.outlook.com (mail-dm6nam10lp2100.outbound.protection.outlook.com [104.47.58.100]) by mx0a-0016f401.pphosted.com (PPS) with ESMTPS id 3wjp2y9u15-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 29 Feb 2024 08:32:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Yorq5NNgjVq6Z0hsmaXHKIn2x/c1oAcOEyxCFWN9P83gBF5gGfROqSTP5A1wLD9fx77v2ZkDpR01ysCez+XeiHFbGs5rVFxTSRCXIOrLg95IjzXcNlasRAR4ivAJAm/w3x6HGprqRSX5mN9qDDcGiyeVki+afpv/yenlVkgB2ztEpr437D47QMSWf9dH1CSgqNQ5otb4+P/Pi8qQ1Mk9C675Zufp1GM3DSBz86nnxn5B8u5Hq2EvMgTN/eBd/4dE6vF5qJ34XxYTKR5fgLvMkTkA3++vGCEUT55H6UxmCMF+WN/ubfrOu2ud7Em2Jm4I5VpDsZt7++3jNp2Ey9DIQA== 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=4uaWgQoy6YDhwBSn0tPkBZ/RIN+Y7eexoaAQdVOBy7E=; b=HCSOL/hTx58cPwZd0DFJqmfPKo9CY/ItybWzdahAWd5sKS0OdSKaCvt0NJpCnbcX572+sm0UWdW2QPw1cZ4jJpYtVIqQ9Gpv2wmrO5OQXsjkb663t6BYDoXJjOWnq9pQAx14ZExPVdIr3K4LQhk7hL9PDFndcQwcoZJWAe/V/UMbg5QF0TCoa+H+WlIE7uOlePmH/0TJq5zv1VHqYbUNvjbliQ4LzIzqwUFThilm9rCEuiN6WzqzH/bUTpHhF537SI1AOgMrZNx2qKLQe9tvqDY9FO8VYdTu8JKnIAFwCrq7wd853eCDyqPeraLAD9FinInGT2+cAVL9nz8ouIjQ5A== 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=selector1-marvell-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=4uaWgQoy6YDhwBSn0tPkBZ/RIN+Y7eexoaAQdVOBy7E=; b=E+ndyFc9LT+FzOvJn6KI0bhoIOZyuHxks9V+upWtOEpXnAB0r2y3yCDTJqMxyzIIpHQjYBtGYOmO0KSy3ltSWfRO7EYzlLadKHaAKZsEeDMzmDXWAwvu5gv0gy7TYaeVftVSCIhSV4lt+CDyujMDva8gFZa/Emmw5mxgIV7gXKs= Received: from CO6PR18MB4484.namprd18.prod.outlook.com (2603:10b6:5:359::9) by DM6PR18MB3617.namprd18.prod.outlook.com (2603:10b6:5:2a8::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7316.41; Thu, 29 Feb 2024 16:32:21 +0000 Received: from CO6PR18MB4484.namprd18.prod.outlook.com ([fe80::9345:cddf:24ca:5be9]) by CO6PR18MB4484.namprd18.prod.outlook.com ([fe80::9345:cddf:24ca:5be9%4]) with mapi id 15.20.7316.039; Thu, 29 Feb 2024 16:32:21 +0000 From: Akhil Goyal To: "Dooley, Brian" , "Ji, Kai" , "De Lara Guarch, Pablo" , "Power, Ciara" CC: "dev@dpdk.org" , "wathsala.vithanage@arm.com" , "ruifeng.wang@arm.com" , "honnappa.nagarahalli@arm.com" , "Jack.Bond-Preston@arm.com" Subject: RE: [PATCH v4] crypto/ipsec_mb: unified IPsec MB interface Thread-Topic: [PATCH v4] crypto/ipsec_mb: unified IPsec MB interface Thread-Index: AQHaayuxbsUnQwZXw0G1EZ4JKBQDv7EhgcHg Date: Thu, 29 Feb 2024 16:32:21 +0000 Message-ID: References: <20231212153640.1561504-1-brian.dooley@intel.com> <20240228113301.934291-1-brian.dooley@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-publictraffictype: Email x-ms-traffictypediagnostic: CO6PR18MB4484:EE_|DM6PR18MB3617:EE_ x-ms-office365-filtering-correlation-id: 5d488882-a835-4944-d2f4-08dc394400d5 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: LXF57Ym0MWwsVmXxmnDrMGLuTZ4/l5xG1GQ1D0CG1iAo7XVFyjD3GLJXSK6Qeqk5Y7fZ8jlYUbQppd+ahPXuRD5CnEnAGPRagYNOzAn3VJR0NO0c9iPpUnXHf2FGoCYEUGHryFeLeP2+NW7Ke28DE8L0YsZaQijbgcKg1UOmSB6EDgFn1QzNLoZgVtjfHnH+xti3R0wa43z/RTS9Ra7sL9Z6ex3bn1tdbX5kvKtbOWr4b47/OLsoIyaU4ZBoHtOzRd5HAHQwzD7qter5tirEpkCUnraSUIbwEymginj9en5n281UdBx/o+sq1KL3GTnd3RHSfIuP1QrTo8F9xSC0zPi6yhKj/zq3u58iqw3qLntqSZjG9hqSyXAMYcaUV0tRb0JQ8C90aeIugz7BwdQmIY4OEE5Fk56xdqaiLuHp3FOpdFe6hhz/RgZoTLzS2B95h+TNq5yk3Wor/SDlY699kFH0/TvjSeGPEJLmmfu95W+hUxrjKvzyck+p62YPxVEdrpkLXZHWLldCT/aPYUp/5Hyc5Yt6MTzVGBejRK7uK5KoAf5BXUS32fpL/zJz1bclJDa3XT3rvDpVxHpVxXOHInuZAsr/L7lAImWRyjoJF9ws+tiqwhhQjfLQq3Xv7nkNJTWX9azaMDiUmvN7HDQ4nwrhmDS3vbLsUxG2HuZKo+8= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CO6PR18MB4484.namprd18.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(38070700009); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?i3rqHTt2dQjyOvHuKm+W0IMbizFHABhH3oGJztKpKoRa4tvucVYvXjwzSkTq?= =?us-ascii?Q?quwEhoUxr8A9L9yuCq3r071m0QX/907coOyeWmN27eJLlLtq4fzJTY2ckgpM?= =?us-ascii?Q?jOv+j6Yq0uOp+adnON+epZGVOobwlsufjePo40RRwkaWJku3nHwEffy4RkFf?= =?us-ascii?Q?I4VwXjAhkh3ASTziRO8zvG6XZnHPpms3653keACz9j9ybCiSIe4lPaBAexiB?= =?us-ascii?Q?1XeIsWh15UBHexWihBR9AJwhZ8dP3vW3lUaBFUi1jKY55oJuTme5EOTX/ww6?= =?us-ascii?Q?3ge0D8PyM7PkrhfSfIiUBFhzYcCSlGGSPdJI0hEjpT+WjVBPA8koxSksXwAt?= =?us-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1vg+ovlkr?= =?us-ascii?Q?Ai1YZbtF77snDDG979RxclC4isBQr0gGipSYLaWeHE6GIc+1/EnRznkLVoju?= =?us-ascii?Q?H2Ny32iSuiuVs7oXI0jRA0yZU0zKOzlMtE8Z7seAlnGvLuj0gJRFsHP0q2CP?= =?us-ascii?Q?/YU7iM8RYbnTxV0P0/eL7L4VYYW5yFr6CkVwyewPlwShcagJ57usCLluCCXY?= =?us-ascii?Q?Pm4C96TBkO4PLFz96f9sKNEzQoQw0LOLF/+WjNQ/iIzWi6vFIBGWOUH5fs7P?= =?us-ascii?Q?7VY3UiD0g2gsksq25ssA1FzAxUuDdlQtuDEwU/tavMkBOAW7LDqq/lUi5z0u?= =?us-ascii?Q?Ssdjb/gjEuq+wkB2ymTpnqk453hvAqoulX9BrtQy?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: marvell.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: CO6PR18MB4484.namprd18.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5d488882-a835-4944-d2f4-08dc394400d5 X-MS-Exchange-CrossTenant-originalarrivaltime: 29 Feb 2024 16:32:21.4274 (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: nJIZiHMgYNW2WJ2UHe6QOseHZsm9mlQyVBL9qIj7UvdQZoVABhEvca4vvkog/gYGuDgWU8QQewjZyGSmneEs0A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR18MB3617 X-Proofpoint-GUID: WwXHbTCbcbLl3rvP79jlKbwbq7k-AnXv X-Proofpoint-ORIG-GUID: WwXHbTCbcbLl3rvP79jlKbwbq7k-AnXv X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-02-29_02,2024-02-29_01,2023-05-22_02 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 > Hi folks, >=20 > The introduction of a more unified IPsec MB library for DPDK is causing t= he > snow3g tests to fail on ARM. Artifact here: > https://lab.dpdk.org/results/dashboard/patchsets/29315/ > PMDs using the direct API (KASUMI, CHACHA, ZUC, SNOW3G) will use the job = API, > from the AESNI MB PMD code. > We have come across a similar issue in the past that related to an offset= issue as > SNOW3G uses bits instead of bytes. The above link does not seem to be working.=20 I believe from now on, since we continue to maintain two separate repos, it would be better to get ack from ARM folks as well before merging anything onto crypto/ipsec_mb PMD. Arm folks, Could you please get the below change tested/incorporated in the= repo. >=20 > commit a501609ea6466ed8526c0dfadedee332a4d4a451 > Author: Pablo de Lara pablo.de.lara.guarch@intel.com > Date: Wed Feb 23 16:01:16 2022 +0000 >=20 > crypto/ipsec_mb: fix length and offset settings >=20 > KASUMI, SNOW3G and ZUC require lengths and offsets to > be set in bits or bytes depending on the algorithm. > There were some algorithms that were mixing these two, > so this commit is fixing this issue. >=20 > This bug only appeared recently when the ARM ipsec version was bumped to = 1.4. > It appears there could be a similar scenario happening now and this is a = potential > fix that needs to be made in the ARM IPsec-mb repo: >=20 > diff --git a/lib/aarch64/mb_mgr_snow3g_submit_flush_common_aarch64.h > b/lib/aarch64/mb_mgr_snow3g_submit_flush_common_aarch64.h > index 13bca11b..de284ade 100644 > --- a/lib/aarch64/mb_mgr_snow3g_submit_flush_common_aarch64.h > +++ b/lib/aarch64/mb_mgr_snow3g_submit_flush_common_aarch64.h > @@ -94,8 +94,8 @@ static void > snow3g_mb_mgr_insert_uea2_job(MB_MGR_SNOW3G_OOO *state, IMB_JOB > *job > state->num_lanes_inuse++; > state->args.iv[used_lane_idx] =3D job->iv; > state->args.keys[used_lane_idx] =3D job->enc_keys; > - state->args.in[used_lane_idx] =3D job->src + job- > >cipher_start_src_offset_in_bytes; > - state->args.out[used_lane_idx] =3D job->dst; > + state->args.in[used_lane_idx] =3D job->src + (job- > >cipher_start_src_offset_in_bits / 8); > + state->args.out[used_lane_idx] =3D job->dst + (job- > >cipher_start_src_offset_in_bits / 8); > state->args.byte_length[used_lane_idx] =3D job->msg_len_to_cipher_in= _bits / 8; > state->args.INITIALIZED[used_lane_idx] =3D 0; > state->lens[used_lane_idx] =3D job->msg_len_to_cipher_in_bits / 8; >=20 > Thanks, > Brian >=20 > > -----Original Message----- > > From: Dooley, Brian > > Sent: Wednesday, February 28, 2024 11:33 AM > > To: Ji, Kai ; De Lara Guarch, Pablo > > > > Cc: dev@dpdk.org; gakhil@marvell.com; Dooley, Brian > > > > Subject: [PATCH v4] crypto/ipsec_mb: unified IPsec MB interface > > > > Currently IPsec MB provides both the JOB API and direct API. > > AESNI_MB PMD is using the JOB API codepath while ZUC, KASUMI, SNOW3G > > and CHACHA20_POLY1305 are using the direct API. > > Instead of using the direct API for these PMDs, they should now make > > use of the JOB API codepath. This would remove all use of the IPsec MB > > direct API for these PMDs. > > > > Signed-off-by: Brian Dooley > > --- > > v2: > > - Fix compilation failure > > v3: > > - Remove session configure pointer for each PMD > > v4: > > - Keep AES GCM PMD and fix extern issue > > --- > > doc/guides/rel_notes/release_24_03.rst | 6 + > > drivers/crypto/ipsec_mb/pmd_aesni_mb.c | 10 +- > > drivers/crypto/ipsec_mb/pmd_aesni_mb_priv.h | 15 +- > > drivers/crypto/ipsec_mb/pmd_chacha_poly.c | 338 +---------- > > .../crypto/ipsec_mb/pmd_chacha_poly_priv.h | 28 - > > drivers/crypto/ipsec_mb/pmd_kasumi.c | 410 +------------ > > drivers/crypto/ipsec_mb/pmd_kasumi_priv.h | 20 - > > drivers/crypto/ipsec_mb/pmd_snow3g.c | 543 +----------------- > > drivers/crypto/ipsec_mb/pmd_snow3g_priv.h | 21 - > > drivers/crypto/ipsec_mb/pmd_zuc.c | 347 +---------- > > drivers/crypto/ipsec_mb/pmd_zuc_priv.h | 20 - > > 11 files changed, 48 insertions(+), 1710 deletions(-) > > >