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 9AE5A41D8D for ; Mon, 27 Feb 2023 08:15:11 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9615540ED6; Mon, 27 Feb 2023 08:15:11 +0100 (CET) Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2060.outbound.protection.outlook.com [40.107.93.60]) by mails.dpdk.org (Postfix) with ESMTP id 26D6940A84 for ; Mon, 27 Feb 2023 08:15:10 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HDH19VslslGtqArHMNGnN6VHhLYDa8cKLfYcKCkugvWeJgSlb1Mv5cdW9IEGp4G3aBwN4NGvxl1rfD8Yyl2CezEn9kDuOPRcyJrcL4m91K8ZtHrgS0Hz2wOf2Ka/SaCVvJQs8ZguVe37F87896JChp5iCry/qME2ZA5jrOfYnRaqb781n7Dc+gY5APCPjuCHcHex2Zp6LlFRGeCbFs6DiRilxwpWumQ6ZYZMsMLQVvJPRmgz71g67zJY1wFebjxmXsE0vZScvCIL2G4VnZ4kMPx5AXuDC5C01dIL6dQ2o+75OhX0GXW9eDLUAodcACC/SQ3Sk0e7rLi1ZrnKV4uP+g== 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=4Zh14XYUuW/BYKBlepyeSmwqG43K6eecPTBXAEhiVmQ=; b=ZuOTpj/tjEuyXEkJqZg5Y5lXTVcQRA3yYf1ivqi17F6tMvStMb6Nnor6y+j6T7PHGbnFZpR0lb5iHAoYh3FTUX07qx4G4JumTpHY3eFhXebxf3x6NfADh0gslOzID+Qj+lbzYPgUsBH7jZV8nY+tU7a4b3Pci8L+FN5Ft/E3iQ7si1iK1fG72ZF8f4/pBNTb3dgEdkRHJSxOrd9mf5pOnGqscs1ahCjU8P1uKdrecDfssS1fk+88iUoIc/MR52GCULUrnSSNpQsZB7x2EEI6Nk48nZiBkhSDBTN1o9fvMnkg2dxjQa1JhOQFdinpozjEwZ1/fbNDblWP/owKIs8bQg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.160) smtp.rcpttodomain=dpdk.org 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 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=4Zh14XYUuW/BYKBlepyeSmwqG43K6eecPTBXAEhiVmQ=; b=L2Rl/1bsuQAQue3PYXS8/U6GcajL4rpdAmLW/1IY/rkfS0e7ZV3B1AI34IboWfRnc8Bsg6RCmiJvrxjsiuDwvsP/edGhYmDWl3N3Jpi8a/Isozb6ghzJaK5zO+7F7WMfOtxJcgfbgGoc473RhJfhUin0B+fQPZfATEQqmZaN3lesvjpeYj12zynnX2Sr469i3LElmPTKQyffILgeK75HCh6NRrPt7DKEcvOl8hZz4rkwdUrZhJ8iP2ASBnhvtG7hU9MAkK5/orxSd7IdaXDU4ar8AtpUBvN617aNZ2dlTnyzUhs4S/GIsuu18VqgJXRX+9xhCvzOQUOxsjSOlyOWMQ== Received: from BN6PR17CA0040.namprd17.prod.outlook.com (2603:10b6:405:75::29) by SA3PR12MB8440.namprd12.prod.outlook.com (2603:10b6:806:2f8::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.27; Mon, 27 Feb 2023 07:15:08 +0000 Received: from BL02EPF00010209.namprd05.prod.outlook.com (2603:10b6:405:75:cafe::2c) by BN6PR17CA0040.outlook.office365.com (2603:10b6:405:75::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.29 via Frontend Transport; Mon, 27 Feb 2023 07:15:08 +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 BL02EPF00010209.mail.protection.outlook.com (10.167.241.198) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6156.12 via Frontend Transport; Mon, 27 Feb 2023 07:15:08 +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.986.36; Sun, 26 Feb 2023 23:14:51 -0800 Received: from nvidia.com (10.126.230.37) 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.986.37; Sun, 26 Feb 2023 23:14:48 -0800 From: Xueming Li To: Alex Vesker CC: Erez Shitrit , Matan Azrad , "dpdk stable" Subject: patch 'net/mlx5/hws: fix memory leak on general pool DB init' has been queued to stable release 22.11.2 Date: Mon, 27 Feb 2023 15:00:34 +0800 Message-ID: <20230227070107.15664-126-xuemingl@nvidia.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230227070107.15664-1-xuemingl@nvidia.com> References: <20230227062349.13764-1-xuemingl@nvidia.com> <20230227070107.15664-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.230.37] X-ClientProxiedBy: rnnvmail202.nvidia.com (10.129.68.7) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BL02EPF00010209:EE_|SA3PR12MB8440:EE_ X-MS-Office365-Filtering-Correlation-Id: 3758f448-6efa-4058-3a47-08db18925b8c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: XKq2A/25WSD24lp6cN00B0F08hZSrz43kcgNkRYKBmzFtF/KUogSnrKe8e5Hz+E2zA1TmAScg3LMxIZKYLD3rvnisrzoCBN2ud/7EUZUSOUeULufVto+C+lwXB8AdgQQj8/VEBwx4SGdHGJ9wEvEJWoYgyqEgtLoj98bPcxxgMZoWhtHCcQMyke96uIiTAfajKvozGweGNx/yCAbe6d8BAOZjOcx9c5Yk3J2gYdUElG9z0dAjxFSxAXwaDYqjtXY1WLDdTX/ydWu3hkmkD9gsYy9LVQtx3kYKy3fcZpk5RHz4qFEK+XZP534Lv2r9bw/0mkBfV+Iwpgi6v4y/ajO7UL5A7mtvQqs2nZk+R+k033t90S4sly0lCHGtMNtQaUvlz7GYoIOEpgJ7HsWHtY/dlbYVSMgi+xlANlrVBuOoplWlHlS/BQWyKasFlf5sN2vB7ejG+Ns/l4TUBSiqF9YDAGY0Hjw58SokzXIpWoUOa0HYz+aBBTwDsXqSGmCFAvPi3Ni9blzLKqiaHQxk1AVI1QHIAqsaVI0FJ5aG1Ee5HgEtpg5nFfTxjde8A9L7/nFHrSBTdi86J+01LCXxYGALLD3bPbjKk6TSWCMh5LWhneY1ofP3/O0cznqnMDkEezBqX8rOgSgP72w7vECQ5yUuoQQdPt5publFq5I8DeeiFFdYkgW2VQ7TAZI0GZcNQtoM2lNEFQeZBjnI58RE4arXoEbc23QAj86E+5XfmgtcUvtSbspr2gm4F+Y9QiSMlft3EXCFB5UopDbemLU70acoE+mFRe1qjd5nUj/Rux0eWA= 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:(13230025)(4636009)(396003)(376002)(346002)(39860400002)(136003)(451199018)(40470700004)(46966006)(36840700001)(83380400001)(2906002)(426003)(47076005)(2616005)(82310400005)(70206006)(70586007)(478600001)(356005)(8676002)(53546011)(16526019)(36860700001)(26005)(6286002)(186003)(4326008)(5660300002)(41300700001)(8936002)(1076003)(6666004)(7636003)(6862004)(82740400003)(36756003)(336012)(37006003)(966005)(54906003)(7696005)(40460700003)(86362001)(6636002)(40480700001)(55016003)(316002); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Feb 2023 07:15:08.1233 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3758f448-6efa-4058-3a47-08db18925b8c 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: BL02EPF00010209.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA3PR12MB8440 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 22.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 03/01/23. 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=22.11-staging This queued commit can be viewed at: https://git.dpdk.org/dpdk-stable/commit/?h=22.11-staging&id=9e0308d5ef3c884ed4a76db16735d2dec2cfc279 Thanks. Xueming Li --- >From 9e0308d5ef3c884ed4a76db16735d2dec2cfc279 Mon Sep 17 00:00:00 2001 From: Alex Vesker Date: Wed, 11 Jan 2023 21:49:03 +0200 Subject: [PATCH] net/mlx5/hws: fix memory leak on general pool DB init Cc: Xueming Li [ upstream commit 86ed522a82059896263ca8c7488403fccf62c6a7 ] On elemend db init we allocated the element_manager which was unused and not freed. Fixes: b4dd7bcb0dcbe ("net/mlx5/hws: add pool and buddy") Signed-off-by: Alex Vesker Reviewed-by: Erez Shitrit Acked-by: Matan Azrad --- drivers/net/mlx5/hws/mlx5dr_pool.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/drivers/net/mlx5/hws/mlx5dr_pool.c b/drivers/net/mlx5/hws/mlx5dr_pool.c index fdbd3d438d..af6a5c743b 100644 --- a/drivers/net/mlx5/hws/mlx5dr_pool.c +++ b/drivers/net/mlx5/hws/mlx5dr_pool.c @@ -464,13 +464,6 @@ static void mlx5dr_pool_general_element_db_uninit(struct mlx5dr_pool *pool) */ static int mlx5dr_pool_general_element_db_init(struct mlx5dr_pool *pool) { - pool->db.element_manager = simple_calloc(1, sizeof(*pool->db.element_manager)); - if (!pool->db.element_manager) { - DR_LOG(ERR, "No mem for general elemnt_manager"); - rte_errno = ENOMEM; - return rte_errno; - } - pool->p_db_uninit = &mlx5dr_pool_general_element_db_uninit; pool->p_get_chunk = &mlx5dr_pool_general_element_db_get_chunk; pool->p_put_chunk = &mlx5dr_pool_general_element_db_put_chunk; -- 2.25.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2023-02-27 14:08:44.956006200 +0800 +++ 0127-net-mlx5-hws-fix-memory-leak-on-general-pool-DB-init.patch 2023-02-27 14:08:40.909237000 +0800 @@ -1 +1 @@ -From 86ed522a82059896263ca8c7488403fccf62c6a7 Mon Sep 17 00:00:00 2001 +From 9e0308d5ef3c884ed4a76db16735d2dec2cfc279 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 86ed522a82059896263ca8c7488403fccf62c6a7 ] @@ -10 +12,0 @@ -Cc: stable@dpdk.org