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 45D654574A; Tue, 6 Aug 2024 12:28:27 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2269342DDA; Tue, 6 Aug 2024 12:28:02 +0200 (CEST) Received: from AM0PR83CU005.outbound.protection.outlook.com (mail-westeuropeazon11010065.outbound.protection.outlook.com [52.101.69.65]) by mails.dpdk.org (Postfix) with ESMTP id 5574842DC5 for ; Tue, 6 Aug 2024 12:28:00 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=fbcZ78cf7y8kMzs4amHjCiPznAytEly0HM8RZdFiWmHMW5guUj6rPqPSIAMJh/jrcU2YL6CfCOhlCRMuoetcoRjr+01+s4Pm39XQWT/4Hp5H+eiOj0hyiyAEHgTGGPgc1fbV/YIvFGwDwRGDMReUrMRs4u08KgHW1DKGrLaoJpaR3tV/6EZ5gGHRIA3oSvISTqrCDwfskssv7doHxKo0A0bvZd8FRGLh4Ywz44pCYNyPqFSIcOmwE5oIGzaIQCxYkIPdvtCiq3gl19+yPYa2Kr5O1EG84JcWpEANpSjAnGkQpMfkuhGSe+OZXbJpcC5Z9OdP8HE3ebVJjrSlGqXPRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=bODl4ZK8aK10cNKWt5lSSDQqKYObtRERxpUaA3xaK6E=; b=EzVmGMi+aXLDjN0nzblYEcrB8ZbMGlVl2raX3HKTUtyz2Ir3XASlrmLY8ICTpuBvwALDPLFkf4URbbN41Nl/ab+1FIMIGzPlHMXeSimTOokFAy7bJCBR4iAdli6IrYSXuqpLOnxjILYfdYKZ65wbH2UY54sFecel4qGuYVOmOWqDqRzS0XyshLsAiev0yEqH+ZUKM3yW+nR7Nmxzw0Gq+CaYgcL5jOvW/pUmMIcL4jOvPPc5AgR6HQ2DknbpXju53qSDuPF23GnE02gXwn2KV4wNx/KWSWEKU35mVTBN6mFYedYEWzroGsmi5x1bVZHYXKd37PdkS3H5kUs9lfuiwg== 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=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=bODl4ZK8aK10cNKWt5lSSDQqKYObtRERxpUaA3xaK6E=; b=Gs6xCWzex4n71ud5+lC106BwQ0ewicMiqw2pjX9Z2+Mb3W36msuNcFg7+dTcf8Lf1rRRw1LHlDsRiRl+tByRkg50rVuOWQ0x5kD2tC6XGmhvR1OYN3plfgwC8uNSgfb0QqMFIomCMcX9y5hOKjhjqz3ZTgkzpKEqTQrAF+AbRpj1WSS9osCb8PdVMOlD/9okMoWRxuM1aVob9gUqhjp+KmylEj/NoujvUHfJ11QliwGUg75CrA57AdCBXhwLPB3yTZIGMqzTQWdXie/msBNWTq8pbPMzVtjoiFLWsH3FD9pu74627qsBwGp4xwQc4GjQmEQXgwqfnoiCWw+q7Y2HoA== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AS8SPR01MB0024.eurprd04.prod.outlook.com (2603:10a6:20b:3d0::24) by VI1PR04MB6974.eurprd04.prod.outlook.com (2603:10a6:803:133::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7828.26; Tue, 6 Aug 2024 10:27:58 +0000 Received: from AS8SPR01MB0024.eurprd04.prod.outlook.com ([fe80::c634:479e:8f8a:a325]) by AS8SPR01MB0024.eurprd04.prod.outlook.com ([fe80::c634:479e:8f8a:a325%7]) with mapi id 15.20.7828.023; Tue, 6 Aug 2024 10:27:58 +0000 From: Gagandeep Singh To: dev@dpdk.org, Hemant Agrawal Cc: Jun Yang Subject: [v2 5/7] crypto/dpaa2_sec: enhance pdcp FLC handling Date: Tue, 6 Aug 2024 15:57:30 +0530 Message-Id: <20240806102732.3225536-6-g.singh@nxp.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20240806102732.3225536-1-g.singh@nxp.com> References: <20240806084136.3212615-1-g.singh@nxp.com> <20240806102732.3225536-1-g.singh@nxp.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SG2PR04CA0188.apcprd04.prod.outlook.com (2603:1096:4:14::26) To AS8SPR01MB0024.eurprd04.prod.outlook.com (2603:10a6:20b:3d0::24) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AS8SPR01MB0024:EE_|VI1PR04MB6974:EE_ X-MS-Office365-Filtering-Correlation-Id: 7ba94f26-de23-4a09-88ff-08dcb6027136 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|52116014|376014|366016|1800799024|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?M4zmMo36r7z9cdnxlvs3JLRhlbCHfiWe3Rny9Mf2T0n36D2u5Z69mCDhESfS?= =?us-ascii?Q?BZ67j9yB7F2iWHYi7hmJ7eDcJYR2EfOgEFZBJDt8Nqi46ghxZuDG82HUZ5Mo?= =?us-ascii?Q?aN4M8FD5pKtKVXWnpj2QJe9BeNIAHb58Gm8M13omWdqHSceoAgMz7ex6Qqlc?= =?us-ascii?Q?0L4ybcsvr4mgNiAUL75vkj+nnMy/NG2Hxni20N1iYlfV18aLOoXHuPFn1JuB?= =?us-ascii?Q?I/b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hn7r87KgVRNBimJ9UUiqMzeaHD?= =?us-ascii?Q?41hfY/QVPZSzkkNexlECT4/0CHmURMTOHzxswFE3qC6vtFRPm+qCFASH/Iq5?= =?us-ascii?Q?AYMgk95EvFGt3KFg58UTfs06gAFqOZ6IG3jArFdrYIMIo3ovRh79xb5+xKcb?= =?us-ascii?Q?OXFWvbg+Ln6AbvGWRHL3R4oBDyp47groBMhOzO/rWp+/WPaxWA9REwzz6GyM?= =?us-ascii?Q?7ehRMSgxd9ITkAfcKJDuzH0idcE9EAVVo8rMJu8xp1FpPpDnBCgfSaYK28on?= =?us-ascii?Q?Gjewvvl4DBF4JJMwkAMYakprqTeIPYY5tKfxkGK0PMsnF0ZNGg=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AS8SPR01MB0024.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(52116014)(376014)(366016)(1800799024)(38350700014); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?cvpJvZCXFo2aE09UuzoPvTlLFSI9NWg177vnxRvZ6/z9ZO0253vi8/PcSkVk?= =?us-ascii?Q?wwop3JOSqVPxB+9f7RYjW6OTxpXZoP0dKUYZ9//q65hApVgwuA4FaBOn7EUO?= =?us-ascii?Q?eeSWPnJpKi9o2RpYBX17va0ICsUTCMbw+cNprYDo0PnwSRNHOHEzr0P/ayws?= =?us-ascii?Q?KtArFwxG7J+Li7n/fVzM3G0+AixiPFltSFSKBHb5cvoCdpxJbbUfaA5d8HAx?= =?us-ascii?Q?JWw9GhLhBVcTWfOl0aR8AkNb5Ky75dz0lfJnB3t8YyP3Kh3jSqrLEoG9cezT?= =?us-ascii?Q?6oJr10ebEr7WF6wbx1FgW6JrLjFGLrL9vS7xbSJ2YQpX6FRQfkh3NYMoPRx9?= =?us-ascii?Q?hd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buk0tJqdxP6IdYs9wD4?= =?us-ascii?Q?h9NpXbAoGyH+mcFtJzZPz70HnJq84oBY7wV687eIcL5GaB5yYwoQ2PXOMRES?= =?us-ascii?Q?bORihw+PzprYvc0vYRZWcFOgdoKQDod2AoufKObfa0QQSGD+qa0zpHBazk5g?= =?us-ascii?Q?y4mmpBeubdJuORfq7OnqBrm/kwXLZb8M6QdEtFSu8MGDATESHjV8cBpqJc3T?= =?us-ascii?Q?yRKD1HCwbDWY+S5rDFn2R0x5dQ0PxWZFWRtSJdvDK4PVfOq8nwtRy0le2M9B?= =?us-ascii?Q?aIvgk1QTqAFVfTECJ56NMvL+CgiPDyCoLNF+fiVNHbZ7SP+xU0phhkNPAnn3?= =?us-ascii?Q?p0rzDiqD5191CUyiaQMVub0kKLGfU6Ji6D/uU027?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7ba94f26-de23-4a09-88ff-08dcb6027136 X-MS-Exchange-CrossTenant-AuthSource: AS8SPR01MB0024.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Aug 2024 10:27:58.6859 (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: H1g5eaJkZ6TIKec1VS+2ji3jmFDnPttFebqsFhC/9RONFPmREaAd49/dXchXDx8I X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB6974 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 From: Jun Yang Set RFLC with FLC IOVA address and data stashing only. Signed-off-by: Jun Yang Acked-by: Hemant Agrawal --- drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c index 0e30192b30..ff24a8919a 100644 --- a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c +++ b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c @@ -3389,6 +3389,7 @@ dpaa2_sec_set_pdcp_session(struct rte_cryptodev *dev, struct alginfo *p_authdata = NULL; int bufsize = -1; struct sec_flow_context *flc; + uint64_t flc_iova; #if RTE_BYTE_ORDER == RTE_BIG_ENDIAN int swap = true; #else @@ -3397,6 +3398,8 @@ dpaa2_sec_set_pdcp_session(struct rte_cryptodev *dev, PMD_INIT_FUNC_TRACE(); + RTE_SET_USED(dev); + memset(session, 0, sizeof(dpaa2_sec_session)); priv = (struct ctxt_priv *)rte_zmalloc(NULL, @@ -3646,14 +3649,13 @@ dpaa2_sec_set_pdcp_session(struct rte_cryptodev *dev, goto out; } - /* Enable the stashing control bit */ + flc_iova = DPAA2_VADDR_TO_IOVA(flc); + /* Enable the stashing control bit and data stashing only.*/ DPAA2_SET_FLC_RSC(flc); - flc->word2_rflc_31_0 = lower_32_bits( - (size_t)&(((struct dpaa2_sec_qp *) - dev->data->queue_pairs[0])->rx_vq) | 0x14); - flc->word3_rflc_63_32 = upper_32_bits( - (size_t)&(((struct dpaa2_sec_qp *) - dev->data->queue_pairs[0])->rx_vq)); + dpaa2_flc_stashing_set(DPAA2_FLC_DATA_STASHING, 1, + &flc_iova); + flc->word2_rflc_31_0 = lower_32_bits(flc_iova); + flc->word3_rflc_63_32 = upper_32_bits(flc_iova); flc->word1_sdl = (uint8_t)bufsize; -- 2.25.1