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 824FE45E41 for ; Sat, 7 Dec 2024 09:02:07 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7729640678; Sat, 7 Dec 2024 09:02:07 +0100 (CET) Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2080.outbound.protection.outlook.com [40.107.220.80]) by mails.dpdk.org (Postfix) with ESMTP id 8843340678 for ; Sat, 7 Dec 2024 09:02:06 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=p9iDc4p97S3C6RjMUxvMphks/C5pOUs3Ow9ZgzsA5v4BokNm2UUyWecEa2M9LVr4sS9O5VVx7vDFRjzXSp1ZakJxdYJyyi2zKU7m9HaWgCiJUSc5dx12qa2WBl506Fr0Hjxua8RnXX9HBfXh0w43M9SXEkT6aY9tUqkJWIWcRiI5RrfSBBWivjSZ1E6vOpbAMNvCa7qTZyQutr1hkmA+bWELR8i2EAWQgejjpUBEfrppWr/X0a2e1McPJLPTzVZwzAhjT/i6j7OFbSkZY41vkWYaB9/oiDZKQa+3O4m3yeqtA22gmpQBeDEdo8B1eGuvw/mppRGbCX+ZO1D4WsO88Q== 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=NWKIfzJO7VKlr9Rl9QPfMWHXhFerXpNa757UjH78Cpo=; b=yBtkWn1cIyznSSenQ3tBRcovP60h3NJ8DF7GZqY4uT8gBSALVOFS+m7eTWUQBlqpqlon++q1Y08JFCucYLX/7/RzEf7DXSN79FbrNZMbOmMvbS7BMKSsfDUIJRsgok/U+bf9upgkLfxBadKRpHYmjVnzp+mgyaU1SECB9/FkRJ/mZUmKrdxS6jUwgDso5OTFAW9mtqnADUDv+BDZYw0NoJlm8hcP4jGBzvBwmmHisQ9gqob12y8avQP7DNgi+yVnReH3Aeqkfx066t3do3cg90eHkKpaJOfuyEFZfMIV/juFLN3JkfOAXDybeRfVzKy2i3UcLomBNoBKbbWJ3JJ1Nw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.160) smtp.rcpttodomain=marvell.com smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=NWKIfzJO7VKlr9Rl9QPfMWHXhFerXpNa757UjH78Cpo=; b=JQmTCei272M4FkNKY0bbErK8QR0dt8uxOIiGPXERVMont0+HH/bkFfmIzpNz4M1HPcTgnxhUDgV8inObVtM9UyBeCgxofU/lpMlO7vnzMG6qOmGq7mQxsdSP+V3UGbKkHzN+DWbh/BKlubmYNL4o7wIWyBk8ZE7hQX8Vhjih6xcPnf497q5bHgzakorpLETlq7fhCpRYycLSa6wLbBa75/6Uy1l4LrVn1XFboFPSYPR39PgHiKPRcTB0b9V+3gIVY02yiz1uwbPBI7Y5A4ucMWh5kx3WGMVpTpq7bCv2ZwwIvPsIfr+S8UhRk7LdwB8UANxBxKH+2s/LRbTf5amZAw== Received: from PH0PR07CA0028.namprd07.prod.outlook.com (2603:10b6:510:5::33) by CY5PR12MB6550.namprd12.prod.outlook.com (2603:10b6:930:42::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8207.19; Sat, 7 Dec 2024 08:02:01 +0000 Received: from CY4PEPF0000E9D6.namprd05.prod.outlook.com (2603:10b6:510:5:cafe::6b) by PH0PR07CA0028.outlook.office365.com (2603:10b6:510:5::33) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8230.10 via Frontend Transport; Sat, 7 Dec 2024 08:02:00 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.160) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 216.228.117.160 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.160; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.160) by CY4PEPF0000E9D6.mail.protection.outlook.com (10.167.241.69) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8230.7 via Frontend Transport; Sat, 7 Dec 2024 08:02:00 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.4; Sat, 7 Dec 2024 00:01:47 -0800 Received: from nvidia.com (10.126.231.35) by rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.4; Sat, 7 Dec 2024 00:01:45 -0800 From: Xueming Li To: Harman Kalra CC: Xueming Li , dpdk stable Subject: patch 'common/cnxk: fix double free of flow aging resources' has been queued to stable release 23.11.3 Date: Sat, 7 Dec 2024 15:59:25 +0800 Message-ID: <20241207080055.488538-8-xuemingl@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241207080055.488538-1-xuemingl@nvidia.com> References: <20241111062847.216344-122-xuemingl@nvidia.com> <20241207080055.488538-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail201.nvidia.com (10.129.68.8) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CY4PEPF0000E9D6:EE_|CY5PR12MB6550:EE_ X-MS-Office365-Filtering-Correlation-Id: a660ad79-ad7d-45bc-6155-08dd16956db8 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|1800799024|36860700013|376014|82310400026|7053199007; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?Js42Prxi66VsEY/pclzeJR+Qu7msU0UvkG5KDgu3k7CO6P483GcBtPoSY2Lt?= =?us-ascii?Q?QjGJmSC6KZZIH77nj/LGDEwVp/bTMOuj+Toefe/0iN73GWIqfNV0kDKLr5z2?= =?us-ascii?Q?FA7MwiqBel17K2xZya2icDlSfPNwIKgr96GgQB1VbWz0GKrxQSIrlWEQrcEo?= =?us-ascii?Q?9XPWmu1Rfi7TWxTwfZwN5pmT5JCiuvJAbRBbq7k1CZz7tCFoCdGixfYazg83?= =?us-ascii?Q?WD78gRyIch6r57Cvwvq4yJCwN5QSot1IjRn6I9W+Gf0RoYju9U9fzeQ5vJ4P?= =?us-ascii?Q?692wJfHxRyaP8I+01yyFA0De2t3TJz2Vggj2R7AbUv9JquKuRLtOxKp31hKT?= =?us-ascii?Q?q6B5DRoYEcDLUm9s29tAlaG3aCaBbpSRU7T9ha72d/KJzsLVrOnB2Shj1zqU?= =?us-ascii?Q?5KYWK0j1nBDOTBw2Sv8FXm0+mgzY2hbOWjFP/i56vS10B2MZHvO5rZr7Om/S?= =?us-ascii?Q?Zws1/OArluqmEYE+fsjIBy8+r7e29TsjOKW616iYFQLmUSGkiTpbzDii2/KR?= =?us-ascii?Q?EPK/e2hWZM40BohkW2tJzKeIxqaRhzVE/P0sRCp3ehfFC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lfgT40DzA00hOz3D72MRLbbm?= X-Forefront-Antispam-Report: CIP:216.228.117.160; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge1.nvidia.com; CAT:NONE; SFS:(13230040)(1800799024)(36860700013)(376014)(82310400026)(7053199007); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Dec 2024 08:02:00.2435 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: a660ad79-ad7d-45bc-6155-08dd16956db8 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.117.160]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: CY4PEPF0000E9D6.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY5PR12MB6550 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Hi, FYI, your patch has been queued to stable release 23.11.3 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 12/10/24. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://git.dpdk.org/dpdk-stable/log/?h=23.11-staging This queued commit can be viewed at: https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=53018798593ac88d8b364b32f5b85ad3ce42f8a8 Thanks. Xueming Li --- >From 53018798593ac88d8b364b32f5b85ad3ce42f8a8 Mon Sep 17 00:00:00 2001 From: Harman Kalra Date: Wed, 23 Oct 2024 20:31:37 +0530 Subject: [PATCH] common/cnxk: fix double free of flow aging resources Cc: Xueming Li [ upstream commit d1066ea60bcb5cbd3cdcc06d21afc232d8c08407 ] As part of NPC tear down sequence flow aging resources are cleaned up while they were already cleaned up when last flow with aging action was removed. This leads to double free of some resources. Fixes: 85e9542d4700 ("common/cnxk: fix flow aging cleanup") Signed-off-by: Harman Kalra --- drivers/common/cnxk/roc_npc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/common/cnxk/roc_npc.c b/drivers/common/cnxk/roc_npc.c index fcede1d0b7..9ea96a524c 100644 --- a/drivers/common/cnxk/roc_npc.c +++ b/drivers/common/cnxk/roc_npc.c @@ -351,7 +351,8 @@ roc_npc_fini(struct roc_npc *roc_npc) struct npc *npc = roc_npc_to_npc_priv(roc_npc); int rc; - npc_aging_ctrl_thread_destroy(roc_npc); + if (!roc_npc->flow_age.aged_flows_get_thread_exit) + npc_aging_ctrl_thread_destroy(roc_npc); rc = npc_flow_free_all_resources(npc); if (rc) { -- 2.34.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2024-12-06 23:26:44.374040223 +0800 +++ 0007-common-cnxk-fix-double-free-of-flow-aging-resources.patch 2024-12-06 23:26:43.853044829 +0800 @@ -1 +1 @@ -From d1066ea60bcb5cbd3cdcc06d21afc232d8c08407 Mon Sep 17 00:00:00 2001 +From 53018798593ac88d8b364b32f5b85ad3ce42f8a8 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit d1066ea60bcb5cbd3cdcc06d21afc232d8c08407 ] @@ -12 +14,0 @@ -Cc: stable@dpdk.org @@ -20 +22 @@ -index 8a951b6360..2b3c90683c 100644 +index fcede1d0b7..9ea96a524c 100644 @@ -23 +25 @@ -@@ -389,7 +389,8 @@ roc_npc_fini(struct roc_npc *roc_npc) +@@ -351,7 +351,8 @@ roc_npc_fini(struct roc_npc *roc_npc)