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 5FBCD45610 for ; Fri, 12 Jul 2024 12:46:58 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5832C402E5; Fri, 12 Jul 2024 12:46:58 +0200 (CEST) Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2088.outbound.protection.outlook.com [40.107.220.88]) by mails.dpdk.org (Postfix) with ESMTP id C778B40261 for ; Fri, 12 Jul 2024 12:46:56 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=kjxyllefK27Owr0O6bHImSE6wwa2GGnED+tfMd2hRSPP/K9/UiH+FTl8w5MK17XRtmJ8on9PulcpfdKDM+jAhccgXLwTfR6kzW7EWIEMS145nZ/lGfFT1EdDs0XFMV3mbhHf8Yf598dLOP1USDiFykCgSGEN3FA7UJo3V7u4KRO/IB0tqRRcIvgsceNVE7G9UXbQ4vgKxMVhTfujq+8Aju0Xdh/2acOxly7u6jvSY5+izV6WnOZWgkZgOyNJNHWJWwtJA201T93rMlzKfmZXTrAQdNbKapIZbGCh2Wz+rSuhJum9f4dbWji0ZnVAM/pYG4En9K0Mn6gQkUyvOwRf9w== 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=aSUW7banx5lcaoahXWfhFVr1+ynHeh4HZIQzZG8/pnE=; b=CzJxb4yRPIA5c8baka0YvpqnfzEMw2lMQSeiqJnm+CcNzOm+qBMz3O1S+r0G6xeNmL/zgjIXaSxFQGB5BRXtXqdMK6m4YTrIPjYsXiewTNz9AZmONUQDspH7X7Y9kCHbMUrmfH70cm68hBJbuCoo0I1f8VqSkKNOcbRviRr6wc5MmlH9T5tdy4kz0lMQ2+k6eJlJdC1uxQMKr8WNOz3Hu7xuY7oaV7oUoApmiWS9uHMD21hm9KiHDsr8zLxFT+qnoPoEsQbDdQHj0wY+khATupJ5XPJEvyZCHWYCVDXdqE4jT1VV6hIKOL4HFySGcmPiV2VYe9dxrV9nPCdHIl3D+g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.160) smtp.rcpttodomain=amd.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=aSUW7banx5lcaoahXWfhFVr1+ynHeh4HZIQzZG8/pnE=; b=LfRaPagnndmj57PVYSJSgZPet6gVR130JlPHSUrtWJkSSZ5YSEVY8atgs+P3vvTlTupJmEdQ3oOYs1QmQtAQdZFPGucipc3hxUtANUD3n0OPUrlz/K7Ae2vgyVSDpQ74U38iNo3ZOr3B8thdhCjy6gfntB2XyzaSy9LCSOKxuM1IpikQGlZr2cpjKXLCNM48cyQD7QjzTgMT5oQQR0WICXZLybD48tJ/EKiupemKW37EU6ETQi6icuOz/4Asd54L8S2rsolxqYb0sGjUJDKFopj454nd4g8hfThO+6zkHb1vHOBxKrKTgj8Z+vnWSElRqPiuVzs3cFbog/PGs9lwHw== Received: from SJ0PR05CA0042.namprd05.prod.outlook.com (2603:10b6:a03:33f::17) by DS7PR12MB8323.namprd12.prod.outlook.com (2603:10b6:8:da::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7762.22; Fri, 12 Jul 2024 10:46:53 +0000 Received: from SJ1PEPF000023D6.namprd21.prod.outlook.com (2603:10b6:a03:33f:cafe::db) by SJ0PR05CA0042.outlook.office365.com (2603:10b6:a03:33f::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7762.23 via Frontend Transport; Fri, 12 Jul 2024 10:46:52 +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 SJ1PEPF000023D6.mail.protection.outlook.com (10.167.244.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7784.5 via Frontend Transport; Fri, 12 Jul 2024 10:46:52 +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; Fri, 12 Jul 2024 03:46:42 -0700 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; Fri, 12 Jul 2024 03:46:40 -0700 From: Xueming Li To: Bing Zhao CC: Dariusz Sosnowski , Ferruh Yigit , dpdk stable Subject: patch 'app/testpmd: fix indirect action flush' has been queued to stable release 23.11.2 Date: Fri, 12 Jul 2024 18:43:56 +0800 Message-ID: <20240712104528.308638-11-xuemingl@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240712104528.308638-1-xuemingl@nvidia.com> References: <20240712104528.308638-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: rnnvmail203.nvidia.com (10.129.68.9) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ1PEPF000023D6:EE_|DS7PR12MB8323:EE_ X-MS-Office365-Filtering-Correlation-Id: 2854df65-cb74-4326-01d7-08dca25ff100 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|1800799024|36860700013|82310400026|376014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?uVMs4cgI2uhcFAU75yzi7PoPmoY006dK+v+tofH7KfWg6YUkgO0nPu9KexA+?= =?us-ascii?Q?eQtP+8Bqi63lcvHRrs9CYbXndpOd/n65+EdYHYbGCu/nxv1kaTaAPCzwF8WM?= =?us-ascii?Q?pZB2AApF/Rb9jybC3jmqXq8O5ZLXSNpnG/ehNzJAv5wZdrzXHVpEtKCtVWk2?= =?us-ascii?Q?13xn3AKUkFhPtUxmTBPgYoZ3D858x1LK7dXgGDuU71RW9YiWrKZP6p2PAbcl?= =?us-ascii?Q?uTylZUEgRtc+YHKcogHLomrVSOEEwZq7vUvMqfXM2xhfy5jr8Kj0sJ4p40IP?= =?us-ascii?Q?tuEUitIlNBsXOhXqpSTX2kiAfeMftFx6xXs/D76NZFmY1WgEQTqvjE5TQ/e2?= =?us-ascii?Q?dbskFesJ1qcfrkptgHCpsJSleJ1Vt1thVohYshJsPNtoCrLOwjUpAzWyoDar?= =?us-ascii?Q?EKONx4gb78A4lrWxwUxY0J4uFU9GD0Q+c/naxwB88co2dCz1otx/VdEQOgiL?= =?us-ascii?Q?2aO/1JR7MfE42QXhIcVPBMOyfjSGNezFk4OJjAwgzxwHeq0H2PDGMugcAp53?= =?us-ascii?Q?FzPFeBBpLTIL6SsMBqDPoPZx72071keeq8LAvi14oaWIi1ye5Y/2EL7fCjO/?= =?us-ascii?Q?Z77QmTEk9DU76lOXRtMIEd1c5CC4BM94zwbNM2sOLryPjDoMx6G5f0l59Ans?= =?us-ascii?Q?/GQNUyAC2feZpX58DYReayGrG5uiruMqjLaF2q5gALYuHCBgqzb8IHvFnm1f?= =?us-ascii?Q?ODXXyA9fB5Vrl60G5z8NsHyNmtv95nDhUQbriSp4HEs25Ecg39Ql8gLzexah?= =?us-ascii?Q?f/kMYZoHXcZgft+tSzk40LTE6toqHmvC6kysSWSLEiLEKqiQYEENev+X1czm?= =?us-ascii?Q?MV173XXXTCpGX/GvYKPmOdFNWPm4qZojQl5y3JHCeOemI2AktoW1Or4KkhwE?= =?us-ascii?Q?rNOTMulDUXkFc5aMsDnDohmg34wJAg+R7IDG+QFu0T4XG+L0D51MQbKtgrZH?= =?us-ascii?Q?M2HpjhbRMhU/4b252uWjp6TzY9Sdamw3Ic+Yx1p+xBQd9wHNFo+/c/y5NvlN?= =?us-ascii?Q?3SlW/ce7ekKn9hxcWvcEqWhr+unsfIQNtbYOMyYoWNomX0689EEEVGp3p2qY?= =?us-ascii?Q?3p73trHwkFZxXeKFI5eSUCy6YlJUovUrsVAdjldZssS/6JbAgpRFZzOY4OuL?= =?us-ascii?Q?hmRSGyN0+W3YUcJaBWl4lceEyI90OlvogXKzN+dr/rQlChzQPH3Fmj29A9ix?= =?us-ascii?Q?NTUni+S07zLXafJrVcBuA43lZGb5hEwUsbJobKFzTSrif243VvcQjkMvsys2?= =?us-ascii?Q?53U4F5q9kfkpNDE4ID8n+rDzbJTH73vgsQBc4OnZk1uzJaqiZXcEh9DUYacY?= =?us-ascii?Q?FU8rLIrguNAFneQnTMhRWS/XwOVdQfreID2nUcxohQiQDFj6a1LmJKHaBDqi?= =?us-ascii?Q?Gey+v/H6FFnYWWLXRs5MYZFaamx5Fntq3TL3ydcsm33PjIy9gaMmVmoF8SsA?= =?us-ascii?Q?PvHiyHIOI60f2ntdjp9FpaqRSyOUSUij?= 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)(82310400026)(376014); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Jul 2024 10:46:52.8357 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2854df65-cb74-4326-01d7-08dca25ff100 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: SJ1PEPF000023D6.namprd21.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS7PR12MB8323 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.2 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 07/14/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=2f51a0fdfb6152de1186000634aba86be17d6bcc Thanks. Xueming Li --- >From 2f51a0fdfb6152de1186000634aba86be17d6bcc Mon Sep 17 00:00:00 2001 From: Bing Zhao Date: Mon, 25 Mar 2024 12:58:26 +0200 Subject: [PATCH] app/testpmd: fix indirect action flush Cc: Xueming Li [ upstream commit ecf408d2aa5e8952aac956b001f3ff1de1af1df0 ] The memory of the indirect action handles should be freed after being destroyed in the flush. The behavior needs to be consistent with the single handle destroy port_action_handle_destroy(). Or else, there would be some memory leak when closing / detaching a port without quitting the application. In the meanwhile, since the action handles are already destroyed, it makes no sense to hold the indirect action software resources anymore. Fixes: f7352c176bbf ("app/testpmd: fix use of indirect action after port close") Signed-off-by: Bing Zhao Reviewed-by: Dariusz Sosnowski Acked-by: Ferruh Yigit --- app/test-pmd/config.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c index 6d605556ff..c7d3a968c1 100644 --- a/app/test-pmd/config.c +++ b/app/test-pmd/config.c @@ -1891,8 +1891,7 @@ port_action_handle_flush(portid_t port_id) /* Poisoning to make sure PMDs update it in case of error. */ memset(&error, 0x44, sizeof(error)); if (pia->handle != NULL) { - ret = pia->type == - RTE_FLOW_ACTION_TYPE_INDIRECT_LIST ? + ret = pia->type == RTE_FLOW_ACTION_TYPE_INDIRECT_LIST ? rte_flow_action_list_handle_destroy (port_id, pia->list_handle, &error) : rte_flow_action_handle_destroy @@ -1902,11 +1901,9 @@ port_action_handle_flush(portid_t port_id) pia->id); ret = port_flow_complain(&error); } - tmp = &pia->next; - } else { - *tmp = pia->next; - free(pia); } + *tmp = pia->next; + free(pia); } return ret; } -- 2.34.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2024-07-12 18:40:14.793739845 +0800 +++ 0010-app-testpmd-fix-indirect-action-flush.patch 2024-07-12 18:40:13.916594250 +0800 @@ -1 +1 @@ -From ecf408d2aa5e8952aac956b001f3ff1de1af1df0 Mon Sep 17 00:00:00 2001 +From 2f51a0fdfb6152de1186000634aba86be17d6bcc Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit ecf408d2aa5e8952aac956b001f3ff1de1af1df0 ] @@ -16 +18,0 @@ -Cc: stable@dpdk.org @@ -26 +28 @@ -index ba1007ace6..f62ba90c87 100644 +index 6d605556ff..c7d3a968c1 100644 @@ -29 +31 @@ -@@ -1918,8 +1918,7 @@ port_action_handle_flush(portid_t port_id) +@@ -1891,8 +1891,7 @@ port_action_handle_flush(portid_t port_id) @@ -39 +41 @@ -@@ -1929,11 +1928,9 @@ port_action_handle_flush(portid_t port_id) +@@ -1902,11 +1901,9 @@ port_action_handle_flush(portid_t port_id)