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 CAC9CA0C4B; Thu, 25 Nov 2021 08:25:08 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 50B9040DF5; Thu, 25 Nov 2021 08:25:08 +0100 (CET) Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2085.outbound.protection.outlook.com [40.107.220.85]) by mails.dpdk.org (Postfix) with ESMTP id 8ED9740140; Thu, 25 Nov 2021 08:25:06 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=BH30h34YZFUY7l4V7PZo682udDxdfHJJXi+u5m3xrpUSjL3PHSY4ZNPjn0PhkXpUbcU+t4m6k3uzGAPANUb34qMTQLLzFfYQ0xGnpAUFkKH/qcW8M0TE4DS9Bf/2wMrQ12ajn55lGWucw9wLwQSDZHBv95B8Xfxx/0RLr+cbjFE2/gpaSmrUf1tSJ7Zc/GnNtHNBqxPCcS5kNTPn8anUs6w6bnhEOnboRBLRKdjNOqpsoViCFoxqYTPfdYj2M6avOLH2s+9LVd2xOQY9ym7Wzqb65Rtv/PVoo/dzdC7STNgnj7BH3MsoVlVyO4R/li7BBLrgrnBOyL5a56N2jD3m0A== 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=5/WKbCoRF/VMaZiT0xcMmy2bcXlkS02P8U8t+XkR/4Y=; b=eU/Px+uUwBULrfKGMmqLQawZs20d+4ByKt6GcJHy4AharxjdcOHAwy9CaQ9cQLL15BixA9+Lfg8JcuzxuUi+oQqDaz3WsrzWqNo/LuymSX9RC0TErz/xKVOHSeZTbnDAmgIL2LN+W8ut9TjhgqUudCgWTbOHKgb4Kew5/juKWYbQCrS6q0NUMBQpBPxWVHZT7CYyxFIWKHVXhFxBF/DyGocWxiOtfGpS2Yi+zhoiuiyHIn8ucoaT1o1tVmmCB4w1ssWHB0y3HjYea/d6C1i0F/VRUeoqaMn9z098n1cBmqHd6lgT56I6jD5flyZn6YbuzJ+Fwh7SzS46W4Ad8qkHUA== 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=5/WKbCoRF/VMaZiT0xcMmy2bcXlkS02P8U8t+XkR/4Y=; b=RRmjkynzM3B2PydL2UaOnojaXh6hZY50Zk3XQ84CwowF9ys6cH25JVccmhUkD63CWbIpCeAwa6RKwcYJ4cYL0Evu5dGugvOApSImFDeFVezxt/ObWGmBhSKD09Ou/5b9pLF6HBttOooe2lC0sxNVAp5+F/XAWIVqpZbt9XQzmeOu/q8gXACIvpr+4kF1/CLzQhRHU1snUBuvvIEeOdPO+gg+UAoV8G+hz1CabkuOT/+eniSx0YzJQrUqlbsFoSLmId7nnHYJzf9qXFFh2D6pS7CrK5wG3+GRNGhh3dl4M7XzSNkOEJ/SU0xe5NoS9T/5GTpTqQZXpS8jaeT89Lf46A== Received: from MWHPR10CA0006.namprd10.prod.outlook.com (2603:10b6:301::16) by CH2PR12MB4117.namprd12.prod.outlook.com (2603:10b6:610:ae::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4713.21; Thu, 25 Nov 2021 07:25:05 +0000 Received: from CO1NAM11FT041.eop-nam11.prod.protection.outlook.com (2603:10b6:301:0:cafe::60) by MWHPR10CA0006.outlook.office365.com (2603:10b6:301::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4713.21 via Frontend Transport; Thu, 25 Nov 2021 07:25:04 +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 CO1NAM11FT041.mail.protection.outlook.com (10.13.174.217) 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 07:25:04 +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 07:25:02 +0000 From: To: CC: Matan Azrad , Michael Baum , Subject: [PATCH] compress/mlx5: fix double close for context device Date: Thu, 25 Nov 2021 09:24:45 +0200 Message-ID: <20211125072445.3146615-1-michaelba@nvidia.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [172.20.187.6] X-ClientProxiedBy: HQMAIL101.nvidia.com (172.20.187.10) To HQMAIL107.nvidia.com (172.20.187.13) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 293db4d1-7998-4694-d743-08d9afe4b364 X-MS-TrafficTypeDiagnostic: CH2PR12MB4117: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:7219; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 2Fwclj5EOT6vuL3BaWS+Cq4IxB+DroVaUODeJPGVSVJgRoDjerbzlgxTDTZuQGC1+G+RHqBqvq0ZbQJsMpk9kBMJ+/HFRE3yRi0s6tyV27sjjer/LqscA/QVlRIYhJx9vAqU5zaXo5rkOzi2ncsmBMiiKKzn9/ZLL45/Kthwg2WWDe9F5cGPRE3dhy0LkWPQ/8eDb/TpyO8lZWuWXwYy1IhvO4RnZK02lD3Rnt7U8V5sD83teShnxAWp/fXhvropPxHDKQsJpyqnzi71RWb35NTxiPVT/W5FWqjoGdVje5OqAOYHHW5wBZCdkORO+AuG7prMmSZGJvQYk1ArDzgF50Jk/2FmVssOlBDG03uyu0MyB7AG6nB2nf/LtihpT7bMQxkwhTh7azMw6pUIPbhKORxEMkTw/y17ePx/eTlTUvuo4tWsnIA437v5RNnWjJN7fJqyZy9+5hMXDzeoNbFYYn2o1rECq6hE/Auj2zyf1n2ANuhv667PaszpRqQpEzAIaY3CB/g56yG4wGLUdK0Gt5yy/CNBDzu9a/Xw0u3NOPE6QZRpbZMrkvVQiAws1oMRAwLnr9CGruZVX3BiKEBy6qQuipQCsMGq/zOHhtFxXkDaoIoM8CMB+cyuzqIApx/GlcuRlFVoa5sSneAscyKMQBaYeOOaXkbyMJzgdZvs3IWgUniTqwqLNQbK2WFs3cXXG9VrxsNY6fR0sjrR38nFUw== 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)(36840700001)(46966006)(2906002)(36756003)(186003)(16526019)(82310400004)(2876002)(8676002)(86362001)(336012)(55016003)(450100002)(4326008)(47076005)(316002)(8936002)(6286002)(356005)(70586007)(36860700001)(7636003)(7696005)(426003)(70206006)(6666004)(6916009)(1076003)(2616005)(54906003)(83380400001)(26005)(5660300002)(508600001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Nov 2021 07:25:04.5751 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 293db4d1-7998-4694-d743-08d9afe4b364 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: CO1NAM11FT041.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH2PR12MB4117 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 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 ther isn't enough capabilities to support compress operations, it closes the device and then common probe closes it again. Remove the redundent closing from compress probe. Fixes: 2efd26544554 ("compress/mlx5: support partial transformation") Cc: stable@dpdk.org Signed-off-by: Michael Baum --- 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