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 5B5D5A0C55 for ; Thu, 25 Nov 2021 09:18:55 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4C9EE41155; Thu, 25 Nov 2021 09:18:55 +0100 (CET) Received: from NAM02-DM3-obe.outbound.protection.outlook.com (mail-dm3nam07on2058.outbound.protection.outlook.com [40.107.95.58]) by mails.dpdk.org (Postfix) with ESMTP id 7EDF040DF5; Thu, 25 Nov 2021 09:18:53 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Sz4DBjgHA22R48fswtZaMw3cT9bigTYsVy3QyHJISq50pHJW1LCorm4aNEnrkY6TZMUD2EMoOJ70Tp1sxFmJKNXO8VUEmEB3YW6FcBJV+nJQr+j19Z1dEUNgi9glUbFo+hK3B8FYuBJJXNWyzci/Lp8TUbxh3zXbND9ATqb76vAHhTKeX23XEzsVlnygSCK6hnV6jEmoVEugVs5K1o0RZVbRudfJfe+Ss6o1zBktLiflaMm6f5SOMi9+hS2G76wx5qCjk+zD4/1r902hN5hl3KqxLE+3wnlDYKfvnSinoKDS9479O52KK1+aaFKOhR7rcsYKIn7G1F981WYEWaGGPw== 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=kbmbXu+OHE3DX4d1DM/DoqOZH9hKA2VE6KuFCqB6jMc=; b=nnZyEhdfH3v9Uw7YJGdhT887UwR6wwLk2xw5ZDqOkJv+4abPk4VjqEPQa+mmJwbQqoYAxd588sDy6jNYkoEeuUGP5S+1TWRVY1o2kWsZNr/YhDWtXh5chImsOAHqADXbPZHMv67cB+UPWVBnTsaKS2QybbW27qgSUlDaiiWlGxzW+3y70wJSHbZmxSrJEHYuhEMwVWSHanr2eUu4D/K43UD/UJ21qgxMTO/5Z/e3yUZrC+gjQCZErjy+UaBB9a52PLpfVru4KcumjPrH0NnapcFDvOpeWqW21nKMRtlwlReMJMcv6sPPg6JEEPjiwXrikppCxdeoTZ/96j8G9jC3Kw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.112.34) smtp.rcpttodomain=dpdk.org smtp.mailfrom=nvidia.com; dmarc=pass (p=quarantine sp=quarantine 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=kbmbXu+OHE3DX4d1DM/DoqOZH9hKA2VE6KuFCqB6jMc=; b=aclBKmxFlp42LAaMNuD16TJ9BvCNR9H2KYjdzgf2xM4PCzBDr+/tysMX8n0CXT6pWosaktm3z2+7ReVEoc0O1ClWjNRSHXUL+WA9YXv/I5ZTVaju8V15IuoYxjAMXtI9H5TfzAoNAAUZU+R5E4qFa18U+eVWoSYb+zmH3avJIJe7XbBUvyjUR173VqO3Q/H2fKu1Abhtr3Lz1TX+fcLGTsiv5i4KDxgA6lKTgTxOMMOgCYoEcpGdySCOVMjQnkXLzH9PS6BzhVYzmusaLc8Kz5S8Hy71oO8DjCX2GihV8uHJGe12434OYM/rsJSZ40Ad5qRR7/r0n/USRFsifsed/w== Received: from BN9PR03CA0678.namprd03.prod.outlook.com (2603:10b6:408:10e::23) by MN2PR12MB4518.namprd12.prod.outlook.com (2603:10b6:208:266::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4734.22; Thu, 25 Nov 2021 08:18:51 +0000 Received: from BN8NAM11FT031.eop-nam11.prod.protection.outlook.com (2603:10b6:408:10e:cafe::90) by BN9PR03CA0678.outlook.office365.com (2603:10b6:408:10e::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4734.20 via Frontend Transport; Thu, 25 Nov 2021 08:18:51 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.112.34) 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.112.34 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.112.34; helo=mail.nvidia.com; Received: from mail.nvidia.com (216.228.112.34) by BN8NAM11FT031.mail.protection.outlook.com (10.13.177.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4734.22 via Frontend Transport; Thu, 25 Nov 2021 08:18:50 +0000 Received: from nvidia.com (172.20.187.6) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Thu, 25 Nov 2021 08:18:48 +0000 From: To: CC: Matan Azrad , Michael Baum , Subject: [PATCH v2] compress/mlx5: fix double close for context device Date: Thu, 25 Nov 2021 10:18:29 +0200 Message-ID: <20211125081829.3149790-1-michaelba@nvidia.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211125072445.3146615-1-michaelba@nvidia.com> References: <20211125072445.3146615-1-michaelba@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [172.20.187.6] X-ClientProxiedBy: HQMAIL107.nvidia.com (172.20.187.13) To HQMAIL107.nvidia.com (172.20.187.13) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 92ee05c3-8454-480d-5a95-08d9afec366b X-MS-TrafficTypeDiagnostic: MN2PR12MB4518: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1122; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 5NB1ZqFrHeSRzkYb2BNtyzwyu3lxX7uqWLt5wwb7ZauvA1kVhw7KK59q23uzVt61n42dOjB5y6oyX+/sIlOOgkxpolbPuCfCxN1a3KNocs+5A7QGHTJYSRdtqvwLsuI+9wCfZs+lNHcxL86diLSycg405HjYWX2mqmR/sB6yQHvfka49yNHRLJ9bSF0mWi8ad2UPAmxEi1KNk/VDs9iJbJ/EMsDwR3K1G3yQ14h03e9M4BYK20QLQLp32V6dI+UXWXCswewGF8QwBdmDbVpw0Nd1gkXmKyVb73Jqgk5+jj7Jvu0DjE2+ZN5OfjR3XPp7utFyB6xQ8KwJin7ZZpbYK8HKBhekYa+Uo+6iLuBK2DraMX7YgYPboPi8oXVsAkMz4zfQClvCB6+oq4694e6koZZKVxIkSrSiK7IjN1oqRjf/26qlWOsTQ28Nt6NXpcPmHXjNrcFrdBrswqL+QUHqPbzrV/KwxR50C4Ma1COcfNuQB2f45lUbKNt5MCw0wSk94braru1MNyH+jGYSQYjfeztRPxfOCkgChFXjIUioarsfZ49wQ4yRL7mtLVEdvUCVQoohi5rlKK7EMQ9UzWPXC9Q0jPLgPBnAEGGL3UucK6G4B6vrCsnbIAPo52lhP8mBXP34SMlb5w8dAexKstn+IU9tY93p8c4txZJ/zLkzxyQQoL6Z9jk0+Qr3hSX5L6Ew809No7viO1ScuHdu50vxZA== X-Forefront-Antispam-Report: CIP:216.228.112.34; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:schybrid03.nvidia.com; CAT:NONE; SFS:(4636009)(46966006)(36840700001)(83380400001)(82310400004)(55016003)(7696005)(8676002)(8936002)(450100002)(4326008)(186003)(86362001)(6666004)(16526019)(47076005)(54906003)(356005)(316002)(2876002)(2906002)(70206006)(26005)(36860700001)(6286002)(70586007)(2616005)(426003)(6916009)(7636003)(508600001)(5660300002)(36756003)(336012)(1076003); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Nov 2021 08:18:50.6235 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 92ee05c3-8454-480d-5a95-08d9afec366b X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.112.34]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT031.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR12MB4518 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 From: Michael Baum The context of the device opens once in the common probe and closes with its removal. If the probe of one of the drivers fails, it releases its resources and then the common closes the context. But mistakenly in the compress probe, if there isn't enough capabilities to support compress operations, it closes the device and then common probe closes it again. Remove the redundant closing from compress probe. Fixes: 2efd26544554 ("compress/mlx5: support partial transformation") Cc: stable@dpdk.org Signed-off-by: Michael Baum Acked-by: Matan Azrad --- v2: Improve commit log according to checkpatch warning. Add "Acked-by" inside. drivers/compress/mlx5/mlx5_compress.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/compress/mlx5/mlx5_compress.c b/drivers/compress/mlx5/mlx5_compress.c index bb0dc3a5d2..82b871bd86 100644 --- a/drivers/compress/mlx5/mlx5_compress.c +++ b/drivers/compress/mlx5/mlx5_compress.c @@ -723,7 +723,6 @@ mlx5_compress_dev_probe(struct mlx5_common_device *cdev) && !attr->mmo_compress_qp_en && !attr->mmo_compress_sq_en && !attr->mmo_dma_qp_en && !attr->mmo_dma_sq_en) { DRV_LOG(ERR, "Not enough capabilities to support compress operations, maybe old FW/OFED version?"); - claim_zero(mlx5_glue->close_device(cdev->ctx)); rte_errno = ENOTSUP; return -ENOTSUP; } -- 2.25.1