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 2234A4574D; Tue, 6 Aug 2024 12:27:58 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 67BB642D99; Tue, 6 Aug 2024 12:27:54 +0200 (CEST) Received: from DUZPR83CU001.outbound.protection.outlook.com (mail-northeuropeazon11013064.outbound.protection.outlook.com [52.101.67.64]) by mails.dpdk.org (Postfix) with ESMTP id 0B380402C8; Tue, 6 Aug 2024 12:27:52 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=ab6ZxFTgYUAYCa+Ncc/ugYkQYUzlMj8ACY8PG1CcGSmRp1XEdMyiVSGZa8JmxRcKTVraxUtP9xfgvING9nHWAuTTzEitQ18OJzHIHmqMPcGdhy2QG3eo0mv8YJTEWiST2axvN7WO09srepn8f+n1+zmBvSaRZVgLQtnmpSifCFv+Gtii6fOYB+FypNWWlU25+aSWgMz6CBalDQvmMq9Fr5fegDtP0RUXjCnkxBgFW4BHdIEYBNnA9j1JMIsdracufq5MRIpqGy6ZuyGSzV/n6QhMvcJoQJqvspO5JzTVTzda++LT4r64yEN7N2qHHhIg0hcIxWiifTPYe57O51FmUg== 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=myJH23TopUMXiv6044qAFsqwF5LeGM/UwYNeOa9kebE=; b=f1nLbBm4kK3jESyY5lptqbe03+ZLrVF11RBFL9oA8JYn9Wc2bIHeIITW/SFiHDOfF/Hzc5SFDXnJrHdbb1uLYb8v54DgLNg2NYftbTZKnQE8CwOAD676C0BinemPxNd2kZcz5nrdf9AJFR8UJEMU25NDBq8jqWs5XC3jkHp6/0CfJ+mmcum15FaxOnwhBdcxVVw/yhtyZcZHCsJAMy4IspvQJ/TfCCKYo1NdfryOlC7E5ZTuczNfPqs4YImmNrgRqHrxioaD+Vt2cWskChUXU+qztap0Ui/j1QUzhP48JrVl4U2wYQXGOU/XhRQ6/LAMVA/Kxy+G78n1/0pA+fLpOQ== 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=myJH23TopUMXiv6044qAFsqwF5LeGM/UwYNeOa9kebE=; b=h0ZMdzcy5FlFNSv1jmfovybXyA1KLbYbOeq3cVti+L0t8j3lD2USZGC17ngzsZxqqG8pxUxKKTCWl6ygMYPsfdjOJkWNdgbk3EcXZH0C64Ke9k3WEodrjSB/1VwvP/LuLiori7LB8WCSqGQa2B2+CMe9R61DVjma9qCgxSjwwCy+0OCuaPJh+NnbufCEKGIideiNV6RALbThzo9ZDxzjTHG5f7tyes6CXRZ69o/QtiUYOyB8tbniUXzPph/4v9s7vZnd+ThQJyX3r6DKPOmpO1Lf8LarCy/NSW4SQ2sjAADpzeUfDQ+3DFG6wAECcgnhFqKZ8e79WtAN2aYG0XnE2Q== 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:50 +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:50 +0000 From: Gagandeep Singh To: dev@dpdk.org, Hemant Agrawal , Akhil Goyal Cc: akhil.goyal@nxp.com, stable@dpdk.org Subject: [v2 1/7] crypto/dpaa2_sec: fix memory leak Date: Tue, 6 Aug 2024 15:57:26 +0530 Message-Id: <20240806102732.3225536-2-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: c73be0e4-51f8-4b24-df6e-08dcb6026c5c 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?XeiI1E+UOdCEO3IKbDJ4jJaFwX1TfipCOYGB6OJ/tU7q11lpDQWPWblugghA?= =?us-ascii?Q?NukRPOVvEOISZm7uGnwbH8JLlEzfY88R39d2mutJC4iedfT3xSzg8+No6JpT?= =?us-ascii?Q?FgBQp6HEQRpMmW6MofPOGLOsauxlt0pIS0kA6Pxx2K6QSGQOF0oliQu4R7bP?= =?us-ascii?Q?D2XWKMzgNqBJwSADmvu1zm/OfyVqHB/E/Gd5i7tzFgxIAcMHhBur+JuZlAX4?= =?us-ascii?Q?jR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FRD07Utvz7wSEIPedV1/+5dvo?= =?us-ascii?Q?uSYk0WwThHNwWXylnGP3KclgW9zt2hKl5vJkexTZ65/qsWTsU/R3XtyHnDFo?= =?us-ascii?Q?m/ftR/iVpYP5Pj9+PfdcEF051S/FTJK3flU1DPZSA0cCp3p4PYb3SUUWLqvh?= =?us-ascii?Q?asZ9UQP5IdA4ZBZLkAPpCxT0kLif1puPahJStt6MGwCnWQ6ydv6YCtggx9q4?= =?us-ascii?Q?4d4TnDQjVQLmws/zLC/HEW0XgFmlfght6LJ6olsKTfGuJcARn5MMXYvnZvi4?= =?us-ascii?Q?eS2iUWtFnTbHy/nIHIk2XKM4PirP3kanUKXqQAba6L8Tgwz5Sg=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?xagcyarN0WeGBjsh+o8+GkyMv7Ur2pEwWiqLLSy9VLCILnudCeIKIS6amKUu?= =?us-ascii?Q?Z0T6OuBQLwhHCYZK1ik1b681hSCeZP0qoDHOD0gmpL0H8eOsWeJ3cc/sTIN1?= =?us-ascii?Q?WMFJVP4p2zgUxjvmBJy61Wl5YAQRkNzESqSJP490n4MyzOEk646KvuuzPW/J?= =?us-ascii?Q?CPlPdcrtBHp31857bUMmDgIAXqV5IfSIiUn25va20h6E/iEgBLWlF07e8O5/?= =?us-ascii?Q?IHdvrqRTdTGGCXjP9lJBFRKqLdVqo2PoZvRLqsknKbK7NE07+kMTtntducMm?= =?us-ascii?Q?cStMB95Uqnb1ts4LvwP2W/Pcxc7WQstAFU0mbmpfTlx6oFenTNkyht+x5Rgb?= =?us-ascii?Q?QZvqSfiQ6RD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nu3EuK?= =?us-ascii?Q?QwcSHsoBNxc+sOvsAKW/hoFx1d5Ha2MYyTXvOqquJemTHsnLAiS7aUXaQwQ8?= =?us-ascii?Q?3hQ4mTGBeatjg8OmPKekZK6rFwEkmMwXI3zz5x4lewJtTAGxGsvUvEBWZemA?= =?us-ascii?Q?MrY9hYYRxwsD4j92kxYPzDsk3TUWCvKHiVG5xXkdM3i/CSyjvSTQdItIInjQ?= =?us-ascii?Q?lkAcFvU9xa3dYyoGzkAs1OVilzJUrc4uoSy8HLv+bcgH+bjhnRD6Uwo86top?= =?us-ascii?Q?xKBW8oS+GCRj0KYGudWr7/RdXOTztrFkdhUy1+lq+VwjboA82aKiK/36LJB4?= =?us-ascii?Q?9W113QtZUJuOLzNBONwVd+pT2dGjNTaLG1nZK84B?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: c73be0e4-51f8-4b24-df6e-08dcb6026c5c 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:50.6832 (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: 01dphEbmi6mwcZUwknOWgomgQ7ERcGRqVnsrLvf7+gzpag1PunW7mQOzid+Ty5zx 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 fixing memory leak while creating the PDCP session with invalid data. Fixes: bef594ec5cc8 ("crypto/dpaa2_sec: support PDCP offload") Cc: akhil.goyal@nxp.com Cc: stable@dpdk.org Signed-off-by: Gagandeep Singh --- drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c index c1f7181d55..e0b8bacdb8 100644 --- a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c +++ b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c @@ -3420,6 +3420,7 @@ dpaa2_sec_set_pdcp_session(struct rte_cryptodev *dev, } } else { DPAA2_SEC_ERR("Invalid crypto type"); + rte_free(priv); return -EINVAL; } -- 2.25.1