From patchwork Mon Oct 24 11:30:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 8437 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp401279wru; Mon, 24 Oct 2022 04:48:23 -0700 (PDT) X-Google-Smtp-Source: AMsMyM61pA3wG9ZibfoS4f7iS26MRDAMTM7MxJMlR6X1tYvl0oCyKTKOnrOk0i+0+QtIrcy7Nigk X-Received: by 2002:a17:907:728a:b0:78d:2b4b:e7f7 with SMTP id dt10-20020a170907728a00b0078d2b4be7f7mr26652165ejc.269.1666612103703; Mon, 24 Oct 2022 04:48:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666612103; cv=none; d=google.com; s=arc-20160816; b=qyII+4O1SURDhJcyZj4TwahVpb3wCpTeqHNodx92P52YTVmo1wEyRMzboiPerOz2cl 8hvttSKE7WxZq+KdldN2pOnzzgBZtiPL57a4LRjhJZh+O5XgkDQhm8WSJ7oFYwxK1396 UfMqiXQD5Gwxz/1wOY13Eix/Z79yVN5CAau7UNHoWIljD6uBjhPkQSf++SkU91D0Gtwg RUp1NrWzNnA7HNwkNIFaptbiS3U7cs8TaopcBe71w9WjOtz1OgRdPYPlwT5M1uvQiZij wiEviUqFqfPCc/UtaEr2TKQ/udJYm9BMS4lZTnHKk56l6IyuNoP5FA1cCgFIv2ctUj/g 66Eg== 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=cTaKOMTpgM4IMkGXR8tm7Ux2EjWsBdh6cOYuQmE+bs8=; b=jEtRtel1Gs9jxAz3oWhQfflRbKJzi58viHWUquUDMLm40Sn2IasYTB1GtmjRyTxpzl B7oMgXLA5YA0Y08RH2N/t2q0iS0gdHobMg5nJ7R8b/7s00jjjQNuFXykucK/sBl6aU9R tMaLtkG4mHiXfy/5HuTAns1a1eOpvXVGw52tvnhTXFsvV34PYCLDI8DeioBjJsOdKekf nSPwPlKfqytMlBXvaKv/Cj3+lYfpAQ3MGBqschet3fT3SZD8KUvzFzpywulUUAfnwZX3 qQwM+bPCg8GRnIQilnBjmiuT/6sBFCGs3VfDlohUJZ039FFgSdFp7MkGu9rsecX5cOWr 2dPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=ZM6ZOvft; 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 hq10-20020a1709073f0a00b0070fc7c9d71dsi29127423ejc.989.2022.10.24.04.47.59; Mon, 24 Oct 2022 04:48:23 -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=ZM6ZOvft; 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 S231684AbiJXLrR (ORCPT + 99 others); Mon, 24 Oct 2022 07:47:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43392 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231469AbiJXLpc (ORCPT ); Mon, 24 Oct 2022 07:45:32 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 136BC110D; Mon, 24 Oct 2022 04:42:40 -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 7EF48612AC; Mon, 24 Oct 2022 11:41:27 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 90EA8C433C1; Mon, 24 Oct 2022 11:41:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666611686; bh=HCgnyLFXNJ666+RLJs53imFRVFNh+zNwO7IvWGDTFNk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ZM6ZOvftI80SV9fqJBOpp2cPmsKFBC57aIUgBpMI+N73yGuCe/Ls/js/JD7yMDw+I mzbD/ltbfPo74o3f0C8Xwcac2GRBLUgyZD5kUslzioiVQxpLZymGL0oBzr1IdteExM /DoGMI936ryG6l/9HnXWfswcZ5fPF+ttolUBTRaI= 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 4.9 072/159] spi/omap100k:Fix PM disable depth imbalance in omap1_spi100k_probe Date: Mon, 24 Oct 2022 13:30:26 +0200 Message-Id: <20221024112952.087929715@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221024112949.358278806@linuxfoundation.org> References: <20221024112949.358278806@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.6 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?1747569453747382535?= X-GMAIL-MSGID: =?utf-8?q?1747569453747382535?= 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 2eeb0fe2eed2..022f5bccef81 100644 --- a/drivers/spi/spi-omap-100k.c +++ b/drivers/spi/spi-omap-100k.c @@ -425,6 +425,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);