Received: by 2002:ac0:de83:0:0:0:0:0 with SMTP id b3csp1183325imk; Sun, 3 Jul 2022 19:53:09 -0700 (PDT) X-Google-Smtp-Source: AGRyM1sLNolHcosfDA56nGb7DaDSWghGSAotGXYTOEh5IVHjg4FSL9CeJwT670OcQMcj2WAbSLPX X-Received: by 2002:a17:906:9c84:b0:6e0:7c75:6f01 with SMTP id fj4-20020a1709069c8400b006e07c756f01mr26614755ejc.103.1656903189452; Sun, 03 Jul 2022 19:53:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656903189; cv=none; d=google.com; s=arc-20160816; b=ZWysEyz8xbLEGoZkdx0bx83YOp3F67C07qc1KGYg8K5cwBruYObYC6CBX3s8H5ntcv VAjrbAcXjy2C4MdTX5r2GNSmHZ7QaslFWpK8aLjXw44D92sob3WdrUN03U0e3mcRVbCM vF3UT4cQhHLwkILXUAgOdHxqREG6BSLkq+JyEXFswsD5mh8xuKRwejPwz5GCgBFMorIT l7H9X0J5+3hm1+EiO6Hv9oiHMVE6Q3Bi/uj76HqFVBmJKe46Fjsz2Zu8tnbOVKTpXs2F vSMv1j6hKB1P5bTxKUqerueACFd8GSL/ZRqTc71T4yrzboypXIeWUYFq0zyy+hnECIxG 04MQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=CjuPcwnBZ93JW5B+L4fhEt+YTBO0EkrebwJQF/Yx2i0=; b=fSHc//oJGkI874IPN+rpl2bcNHSACBNvAKOv4Cs1CthW/6rinS830YIckEwanPjueA SJYcJSMXpeGjqCGOVDtop6fUZxc4TSPrXch4eoS8MfuUY0kHwGs52SsTVeF8c+QMrKYG rHSaH0EhW+POjVXVn0Ajqyr73VC+mHDSe+qkI9YD5z9fo08uqXyxxOgKjE8tCq+9f6Ge hpMsr5rtYf4ZTujoBTxqBAlPf6l1DXsMM7JEBDuSFzQuf9pj1x1pCv/Oe/3FZ1ntUfTm UjG2hjC3/2uZPCdORufs+Ws83tKsR/tojDoRfqK+BwNFusMPrqG+Y+K/cQwITL/zuS79 X0Og== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z28-20020a50cd1c000000b0043576dfa9a7si11229355edi.194.2022.07.03.19.52.45; Sun, 03 Jul 2022 19:53:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230106AbiGDCub (ORCPT + 99 others); Sun, 3 Jul 2022 22:50:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36966 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229473AbiGDCu3 (ORCPT ); Sun, 3 Jul 2022 22:50:29 -0400 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D7B3E2ADA for ; Sun, 3 Jul 2022 19:50:26 -0700 (PDT) Received: from dggpeml500024.china.huawei.com (unknown [172.30.72.53]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4Lbqvb13Y4zTgSg; Mon, 4 Jul 2022 10:46:51 +0800 (CST) Received: from huawei.com (10.175.112.208) by dggpeml500024.china.huawei.com (7.185.36.10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Mon, 4 Jul 2022 10:50:22 +0800 From: Yuan Can To: CC: , Subject: [PATCH -next] mfd: tc6393xb: Add missing clk_disable_unprepare() in tc6393xb_resume() Date: Mon, 4 Jul 2022 02:48:22 +0000 Message-ID: <20220704024822.70716-1-yuancan@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.175.112.208] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To dggpeml500024.china.huawei.com (7.185.36.10) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add clk_disable_unprepare() on error path in tc6393xb_resume(). Reported-by: Hulk Robot Signed-off-by: Yuan Can --- drivers/mfd/tc6393xb.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/mfd/tc6393xb.c b/drivers/mfd/tc6393xb.c index 0be5731685b4..1f1aa76292d2 100644 --- a/drivers/mfd/tc6393xb.c +++ b/drivers/mfd/tc6393xb.c @@ -850,8 +850,10 @@ static int tc6393xb_resume(struct platform_device *dev) return ret; ret = tcpd->resume(dev); - if (ret) + if (ret) { + clk_disable_unprepare(tc6393xb->clk); return ret; + } if (!tcpd->resume_restore) return 0; -- 2.17.1