Message ID | 20231213223020.2713164-2-gnstark@salutedevices.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:3b04:b0:fb:cd0c:d3e with SMTP id c4csp8134092dys; Wed, 13 Dec 2023 14:31:04 -0800 (PST) X-Google-Smtp-Source: AGHT+IF6pJqMCwv/8IEOMh7y0WDogCJQXq6pESgDnkLeusgsGyhw1yg+AZLf68Uj4tQAcNLW0OjM X-Received: by 2002:a17:90b:4394:b0:28a:d15c:e3d1 with SMTP id in20-20020a17090b439400b0028ad15ce3d1mr1527248pjb.90.1702506663803; Wed, 13 Dec 2023 14:31:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702506663; cv=none; d=google.com; s=arc-20160816; b=I61/rm7Ts4EzhuzgEW2Xq2y6u+81PAvsch1n1+foXswvkCDXOzPn6v+7QDQKxP7DrC W/h5wMxVCR/RMqc0Yqx/42+/FEsVQcUj89pbDynUS4edIM9CkgUZ5i/WXcAU8iLoenmN Yr5evsdBBtQWlPHcgiFbNw8rwfDJA1qm2f/dQmQTAmBCfYDKD3hBayJE5NGPj+SxVzEG wq+/GIiBfabOG9XTKnNx84wHC/E3HODcsaSiBL1eXeGzfdG4a3FndYF1bl8gS7gYLYVI Rpt08A6nYOfKXkokGsUWbRAU5X9WqXRDGEkZJ7g0CzsCFXYiIkQLnVfqOOxYMnT0Nzx9 bYew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-filter; bh=XoyXME9o9D+O65UPeU/S5jya+2cUqz9UKPsZ2HnPzAg=; fh=VGV6ajQ72e9w8REvYqgUr7SYaKNgFpS3GtVmljO5VrE=; b=OK/SVBHLQldXaMMBgFlKr2Iat3zLFeirDY0Jagf/UA2Kp+Pu177Yt71S48yZ2EACxy umW3d4BBQmIJyH2gYKW/0hWiqkwDTxpYc09FLCi+wE3wTwFwtS/qFXcXUW6N32zFMb5w w0MPvO4VrAND6JCScUseSN0FDzeoV/ysQYHMvrrkurrEO0OLang0ADXSQ+B9bvIrCaXe 4Ulmqw6NSj9Y+LBL1y/kZ2Jv7AZ6j3dSxttNfWstDzzJ4FFi5YNO1qI5se1ZSOMlroqh R5PGQTR14oHF2KoX/BPRJnHUCiYURX8KPTEPLmVwYk19Je7gzf+TL7jRY0/pffueRM5o 7KbQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@salutedevices.com header.s=mail header.b="SKe3//fx"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=salutedevices.com Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id ci5-20020a17090afc8500b00286a2b05cb6si54460pjb.145.2023.12.13.14.31.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Dec 2023 14:31:03 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@salutedevices.com header.s=mail header.b="SKe3//fx"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=salutedevices.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 8CE7D809AF8A; Wed, 13 Dec 2023 14:30:37 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1442795AbjLMWa2 (ORCPT <rfc822;dexuan.linux@gmail.com> + 99 others); Wed, 13 Dec 2023 17:30:28 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33766 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229772AbjLMWa0 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 13 Dec 2023 17:30:26 -0500 Received: from mx1.sberdevices.ru (mx1.sberdevices.ru [37.18.73.165]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 72CB0F7; Wed, 13 Dec 2023 14:30:30 -0800 (PST) Received: from p-infra-ksmg-sc-msk01 (localhost [127.0.0.1]) by mx1.sberdevices.ru (Postfix) with ESMTP id B9441100006; Thu, 14 Dec 2023 01:30:27 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.sberdevices.ru B9441100006 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=salutedevices.com; s=mail; t=1702506627; bh=XoyXME9o9D+O65UPeU/S5jya+2cUqz9UKPsZ2HnPzAg=; h=From:To:Subject:Date:Message-ID:MIME-Version:Content-Type:From; b=SKe3//fxK0hC4j86oD0HGI1eY8s0b29DkwwT8aMEH6yR1KFP9ZKeztr/7O45W8okY XXzEFS/17sMuyGgc8LuIewgYlatFjDCodv3aKOYiHjU0anppmVDZY3i1/Fr146bcCD 0spFcFBxYh1CVvDFX8bqeVkL2wschn2SBrDJPYAbWY3jgIh/SU0djZN5cwfZSGNSHO cgIVGExP2fiTJ0lO7aZUuxtWrtJzK/eSevNBJkAoCzN6743TqVm9sgpTGDmhF70NMB e7xwGb3DCcuwRVQi1LOb50WGeOLIrrCdepMplKwEgfLf4ucH6w5v//ENMpS4w5pVLt YP1VaGpuG4a3A== Received: from smtp.sberdevices.ru (p-i-exch-sc-m01.sberdevices.ru [172.16.192.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.sberdevices.ru (Postfix) with ESMTPS; Thu, 14 Dec 2023 01:30:27 +0300 (MSK) Received: from localhost.localdomain (100.64.160.123) by p-i-exch-sc-m01.sberdevices.ru (172.16.192.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Thu, 14 Dec 2023 01:30:27 +0300 From: George Stark <gnstark@salutedevices.com> To: <andy.shevchenko@gmail.com>, <pavel@ucw.cz>, <lee@kernel.org>, <vadimp@nvidia.com>, <mpe@ellerman.id.au>, <npiggin@gmail.com>, <christophe.leroy@csgroup.eu>, <hdegoede@redhat.com>, <mazziesaccount@gmail.com>, <peterz@infradead.org>, <mingo@redhat.com>, <will@kernel.org>, <longman@redhat.com>, <boqun.feng@gmail.com>, <nikitos.tr@gmail.com> CC: <linux-leds@vger.kernel.org>, <linux-kernel@vger.kernel.org>, <linuxppc-dev@lists.ozlabs.org>, <kernel@salutedevices.com>, George Stark <gnstark@salutedevices.com> Subject: [PATCH v3 01/11] leds: aw2013: unlock mutex before destroying it Date: Thu, 14 Dec 2023 01:30:10 +0300 Message-ID: <20231213223020.2713164-2-gnstark@salutedevices.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20231213223020.2713164-1-gnstark@salutedevices.com> References: <20231213223020.2713164-1-gnstark@salutedevices.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [100.64.160.123] X-ClientProxiedBy: p-i-exch-sc-m01.sberdevices.ru (172.16.192.107) To p-i-exch-sc-m01.sberdevices.ru (172.16.192.107) X-KSMG-Rule-ID: 10 X-KSMG-Message-Action: clean X-KSMG-AntiSpam-Lua-Profiles: 182098 [Dec 13 2023] X-KSMG-AntiSpam-Version: 6.1.0.3 X-KSMG-AntiSpam-Envelope-From: gnstark@salutedevices.com X-KSMG-AntiSpam-Rate: 0 X-KSMG-AntiSpam-Status: not_detected X-KSMG-AntiSpam-Method: none X-KSMG-AntiSpam-Auth: dkim=none X-KSMG-AntiSpam-Info: LuaCore: 7 0.3.7 6d6bf5bd8eea7373134f756a2fd73e9456bb7d1a, {Tracking_from_domain_doesnt_match_to}, 100.64.160.123:7.1.2;127.0.0.199:7.1.2;salutedevices.com:7.1.1;d41d8cd98f00b204e9800998ecf8427e.com:7.1.1;smtp.sberdevices.ru:5.0.1,7.1.1, FromAlignment: s, ApMailHostAddress: 100.64.160.123 X-MS-Exchange-Organization-SCL: -1 X-KSMG-AntiSpam-Interceptor-Info: scan successful X-KSMG-AntiPhishing: Clean X-KSMG-LinksScanning: Clean X-KSMG-AntiVirus: Kaspersky Secure Mail Gateway, version 2.0.1.6960, bases: 2023/12/13 21:35:00 #22672360 X-KSMG-AntiVirus-Status: Clean, skipped X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Wed, 13 Dec 2023 14:30:37 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1785207627158387077 X-GMAIL-MSGID: 1785207627158387077 |
Series |
devm_led_classdev_register() usage problem
|
|
Commit Message
George Stark
Dec. 13, 2023, 10:30 p.m. UTC
In the probe() callback in case of error mutex is destroyed being locked which is not allowed so unlock the mutex before destroying. Fixes: 59ea3c9faf32 ("leds: add aw2013 driver") Signed-off-by: George Stark <gnstark@salutedevices.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> --- drivers/leds/leds-aw2013.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/drivers/leds/leds-aw2013.c b/drivers/leds/leds-aw2013.c index 59765640b70f..c2bc0782c0cd 100644 --- a/drivers/leds/leds-aw2013.c +++ b/drivers/leds/leds-aw2013.c @@ -397,6 +397,7 @@ static int aw2013_probe(struct i2c_client *client) regulator_disable(chip->vcc_regulator); error: + mutex_unlock(&chip->mutex); mutex_destroy(&chip->mutex); return ret; }