From patchwork Wed Oct 19 08:26:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 4643 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp212269wrs; Wed, 19 Oct 2022 02:07:07 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4G7CzSxboFBVWN8GQoE28cvRhwxyZVgET1Z6P9BUCYw2Xd+HEu6nKn0+bVWvc2klaeP5xu X-Received: by 2002:a05:6402:d75:b0:459:fad8:fbf with SMTP id ec53-20020a0564020d7500b00459fad80fbfmr6370118edb.0.1666170427634; Wed, 19 Oct 2022 02:07:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666170427; cv=none; d=google.com; s=arc-20160816; b=jXbzAWR1iOQCCVBTExYg7SGmdKZoM1Nq9lfEuWZDScwjasrDrFftf2x896vNarOBuB 3ubisIujqCKO6BXMEA0Lg7gEBJ9W7cLRvtXyJHW3SzEarDqcEvoI4zC/Dn6YXl+yrTMy 6zbM6oeAWtVPOdQ/cjXc0lWuTfNDd2A5Aou9YkKW5iJXKADJVJrMTNFr8oOPSToCVTpt hGYbOAQvwG9Hz0kom9cMef7m2JQiK+KpFs5hkis2+IHCq0qDGXYISP4x8VRmteVaz+Qr GT3Lk/mLGiZZTG4x/irgCDDm4Dvmf1gLFj1HnkloL+zLxOsZkLb946BeAHpOZ4qBjtA8 choQ== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=AvkYwu7Y3jkvZ6alWLtfagXvYipmN3O5BMvV5lnyp0g=; b=fo0hwwcB4kAbBMm3XCrftKwtJvPs2jB59YJ8/qq32X6Cnqme8awAHjWhoqYqorDtfD e0/UdwVaW1kAtwk/BFZi/vh/MaXQrR8VroLA2pUdLTDT0+GBiN/zNwNnS3DnuZDbC5x4 tCvunNuk9iS29rOoPgv9DzUGVHvrHbmUGBQNmxF6rtRgpl7uPmR9vxDBL8oxJGvPNu4g BL4xP0Hi8gBxaxksxcBKmBv9ZVqdoGkcjf4z7kHravw4uiuW9hzHp1mugN4BIG4ycrux lvbHXOiqcmNxVefNvsBfXhWi3fRAmQPxSh09fbveR5jYmpXmFv9gNKkknQ9achHy8E5S bEbw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=vmCu7S4g; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ht22-20020a170907609600b0078de8d119d5si14769072ejc.899.2022.10.19.02.06.34; Wed, 19 Oct 2022 02:07:07 -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; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=vmCu7S4g; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231971AbiJSI6i (ORCPT + 99 others); Wed, 19 Oct 2022 04:58:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50770 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231967AbiJSI5e (ORCPT ); Wed, 19 Oct 2022 04:57:34 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CC92A15FC3; Wed, 19 Oct 2022 01:53:18 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 750CB6181D; Wed, 19 Oct 2022 08:52:21 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 89B50C433D6; Wed, 19 Oct 2022 08:52:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666169540; bh=qfRkPOfBXEFDRbBTB/Q/Jpv5q9piXIqG1CnSctn/W4I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=vmCu7S4geP7VtF91JBYzMEkikmhCXk1uW4RJa0lP+gbPdstsaJaHF9luWTMRYzArf 6X5S7fEXSGR6exgLgTcHfLexNqYfy2w3xqfq+Szob122GL/pUBw+PdVMdPmrjbWI+c 3mq76vMVEqs5iEjENXKq+kP8Ia0B3SllgEvSVSn4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Zhang Qilong , Mark Brown , Sasha Levin Subject: [PATCH 6.0 316/862] spi/omap100k:Fix PM disable depth imbalance in omap1_spi100k_probe Date: Wed, 19 Oct 2022 10:26:43 +0200 Message-Id: <20221019083303.993259120@linuxfoundation.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221019083249.951566199@linuxfoundation.org> References: <20221019083249.951566199@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747106322226308190?= X-GMAIL-MSGID: =?utf-8?q?1747106322226308190?= From: Zhang Qilong [ Upstream commit 29f65f2171c85a9633daa380df14009a365f42f2 ] The pm_runtime_enable will increase power disable depth. Thus a pairing decrement is needed on the error handling path to keep it balanced according to context. Fixes:db91841b58f9a ("spi/omap100k: Convert to runtime PM") Signed-off-by: Zhang Qilong Link: https://lore.kernel.org/r/20220924121310.78331-4-zhangqilong3@huawei.com Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- drivers/spi/spi-omap-100k.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/spi/spi-omap-100k.c b/drivers/spi/spi-omap-100k.c index 20b047172965..061f7394e5b9 100644 --- a/drivers/spi/spi-omap-100k.c +++ b/drivers/spi/spi-omap-100k.c @@ -412,6 +412,7 @@ static int omap1_spi100k_probe(struct platform_device *pdev) return status; err_fck: + pm_runtime_disable(&pdev->dev); clk_disable_unprepare(spi100k->fck); err_ick: clk_disable_unprepare(spi100k->ick);