From patchwork Mon Oct 24 11:29:46 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 9744 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp548761wru; Mon, 24 Oct 2022 09:42:25 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7Hh9Tce4+2ZJg26rdOVL6Anxzv3elfESK0M7OxkHFek4zQZzSseg/YwbOPJGz/6hnBeTQc X-Received: by 2002:a17:902:b70c:b0:179:eb79:cf9a with SMTP id d12-20020a170902b70c00b00179eb79cf9amr33933050pls.130.1666629745639; Mon, 24 Oct 2022 09:42:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666629745; cv=none; d=google.com; s=arc-20160816; b=eJt0LRkIFbLj6UlVGd2t1r3a+sjvjGpExYUHCZ+zyBc5k90/sTpao5eI5b6jF7Oebm wsgNAk95ApdoaPXmvn17MaIE869PeLNqk7HSW1vdWm+nUnWbVUZgB7th1HGHuK5Oiggb DHvVdbs4MaGRXHbDhOGbWyKuBe4UBHDD7yi0f8WqzSvA8Yw+XdNnyNWYnZI5YKrBNGve Xp02x1W2zjL/doY/utcrbBWckzK2wyoT1VJmk9uVjt5D1SvIzXQ4XiyYxvFXLM5D72Pz 45hDNmycYjpZRDiYwqYW5RIEghXUudDhKef/VfEGZR9/oIh1M9Fi5OaPZ6B13u1AAGov ZxgQ== 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=/fDYK22enPx4QXTMtGhRJyXr8DupQAP+IJdWjyXz9rE=; b=qjdJnHqxlLvHg/n0F/pVZZVzhSJKUqt4E8OB9KWfhsq9Y3OuCsyYmYLPC8osKQzhCE omeDjOME17de2GE+xjqy1knLv3lkuiHbp2rFTqjDcm6Kkytwactw3gaTB98vN4f6Nzi4 bmnDcXFup57Yx71m0mnRPS/Dvs/ieiUYiH0QBFDdAYW7Ct6Fq0CnbgklwxV6x63goZAK 65EtHY+RSm8SnPUV5ohUj4Vv5JfmzFml6RQ27PE4QMSRo/CfpJCH0SP8VFQ3+Jsyrsna ffkawpzkUnEkMYEa34jKHxrHna/8Eyntpfbp2qFGtEkNSrK0RmeLFtnFtTi9Wu6a/uVu tuWA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=dw1cR1hM; 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 v5-20020a63f205000000b0045706a2a5f3si35523719pgh.439.2022.10.24.09.42.12; Mon, 24 Oct 2022 09:42:25 -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=dw1cR1hM; 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 S232026AbiJXQlu (ORCPT + 99 others); Mon, 24 Oct 2022 12:41:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35428 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234375AbiJXQlE (ORCPT ); Mon, 24 Oct 2022 12:41:04 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9ABE4CA884; Mon, 24 Oct 2022 08:28: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 ams.source.kernel.org (Postfix) with ESMTPS id C6577B81255; Mon, 24 Oct 2022 12:08:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 27CDFC433C1; Mon, 24 Oct 2022 12:07:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666613279; bh=n6hSCr/yUwW8mNV3+JAkqCanWy4S3tIwyEl58OYzcR0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=dw1cR1hMQ9CrXFHkZCkGB5Gj8PqZTEKLkwzwexzVY/sJA13QcVr5CDfzirmFzeMYM +LkTWCIC2KwzhggmtNS9HsuD03fh/7Yy12kJT53CZMcKzaKEdYXZpIAQ2PHuL0XEwo vz9vcMIeERaYVcpm/0YEAld9KnAJ/FoLcO2zOldM= 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.4 076/255] spi/omap100k:Fix PM disable depth imbalance in omap1_spi100k_probe Date: Mon, 24 Oct 2022 13:29:46 +0200 Message-Id: <20221024113005.039415667@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221024113002.471093005@linuxfoundation.org> References: <20221024113002.471093005@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?1747587952124892242?= X-GMAIL-MSGID: =?utf-8?q?1747587952124892242?= 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 f64d030c760a..89d89ad1064d 100644 --- a/drivers/spi/spi-omap-100k.c +++ b/drivers/spi/spi-omap-100k.c @@ -416,6 +416,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);