From patchwork Mon Oct 24 11:28:42 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 9059 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp444221wru; Mon, 24 Oct 2022 06:10:52 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7cYtXuXtsVBn0y9SNLUNfo0nErEkinlWLbx+gXZfW+T5kz5FBn0Faa4gCHcEplEpS6LM/6 X-Received: by 2002:a17:902:d54e:b0:178:2da7:1bea with SMTP id z14-20020a170902d54e00b001782da71beamr32996222plf.161.1666617052268; Mon, 24 Oct 2022 06:10:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666617052; cv=none; d=google.com; s=arc-20160816; b=b4ByK9Rvsk32mZYpGRkDZd5T+PihOSV7UftIDuQOLYuUDxF/dx/pn7a+AjjlzIvXIz f+OGSwz30IlJb1KiPVQPQ2Oc0BR7QZzIVfOoeGyPl9Ci5CwccLcoCdUMoq0N9jfUiMfL k/fdxFVzO/xCegDkfaG6I3VYn/3EJ+BMz7w4DAQVv6/J2Gq5697+9q+YQtIjQ8ujg6NV 6sPJcgIiS9M5F0snLAMtRE0aABKVUwZBhsj5qZyM70Q4ZqDt+7PrtssPwBwFapbAEZwi 1S6nKAw+I2rm+DJzC4uhR9vBsUc/lynt04tkO6nxsiWhsIUwYmKHUPS4EDJfaolvOp38 uQ6A== 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=WuDSsDT8WHAbNOlWOGiDfSnm+0l7wrim12FJBLAkaTw=; b=RWVn/Xcjug9U6G2/+4nV4Ds03lKs++jh9ARqOuAkYrjqGs05Q7IKRfjAFjY0Mxz30M vcooWe8sdmPLcOIocTRbzhPLxtyfmqUSikU83gBQFcKr/D1iXPrIQJvmiQuY5ACTfbbG j+r5WOs1Rm6iH+mD8RihWLQixRB718vtVyrcqyba72P2JoSaZPh5yHHDYxAKViq0/O5z YZokawEHFSMFzMdxIIYLq2U/rpP8afPGQjkwiiJ/sfzcco91v6008HPJ4W/cITrvEJVA MRzLS9nrXBC2az+1nNxA8/7BdYdOZ4PMRNGu+kf1UlB+D30k0S1SUjOE5su0Q+cgkCUT 9vKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="SE0/xL9p"; 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 z17-20020a1709028f9100b00186bb2e85c4si266765plo.429.2022.10.24.06.10.38; Mon, 24 Oct 2022 06:10:52 -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="SE0/xL9p"; 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 S235530AbiJXNIs (ORCPT + 99 others); Mon, 24 Oct 2022 09:08:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57222 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235498AbiJXNIV (ORCPT ); Mon, 24 Oct 2022 09:08:21 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4AC099DFAF; Mon, 24 Oct 2022 05:21:24 -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 1DAA1611B0; Mon, 24 Oct 2022 12:21:20 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2E40DC433D6; Mon, 24 Oct 2022 12:21:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666614079; bh=GVYsaKKXtS7tkqz2R3xxZid3DEplSAk80n6tHg3gJLg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=SE0/xL9po31m3Umx+VZ11KzqfkhE8tPC9vSAJJRxoneHnn2SgLvPNGzUORH1nm9cl ZJF6POsix5iuxtFBH++0l7DEDC/1R6/xFUAdPgq3Gbwum/OULNCDRJdnnYNJjQ9C2m CknbOPex2oUGrs+FfOKqyuoZSlJLtTu+q/S6rxy8= 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 5.10 125/390] spi/omap100k:Fix PM disable depth imbalance in omap1_spi100k_probe Date: Mon, 24 Oct 2022 13:28:42 +0200 Message-Id: <20221024113027.989164463@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221024113022.510008560@linuxfoundation.org> References: <20221024113022.510008560@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?1747574642141696769?= X-GMAIL-MSGID: =?utf-8?q?1747574642141696769?= 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 0d0cd061d356..7c992d1f4abd 100644 --- a/drivers/spi/spi-omap-100k.c +++ b/drivers/spi/spi-omap-100k.c @@ -414,6 +414,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);