From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BBCF646B5 for ; Mon, 16 Jan 2023 16:10:51 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 42A58C433F1; Mon, 16 Jan 2023 16:10:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1673885451; bh=1ev8rXNtWGu2KpbGav/gHC5f3N/4xwsQPFGYzi7DUzc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=V+xQK8jY8MWMSnPbwJdcMrnz/a4wBaQW5hU91/pMVDtEBGH2TOaynO1K25RRCvToZ 0+Ke/fKIXjwaeK79s1xJ449a0ys/ZuPsQGGe/r8Fa9PrGGeSxJDVxDOjSJx5sULPFP 8XfQBXKm9hHOF8mG0hxWUdXR5d6rWI0dJ/7bCMTU= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Zhang Qilong , Nishanth Menon , Sasha Levin Subject: [PATCH 5.4 029/658] soc: ti: smartreflex: Fix PM disable depth imbalance in omap_sr_probe Date: Mon, 16 Jan 2023 16:41:57 +0100 Message-Id: <20230116154910.946182108@linuxfoundation.org> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230116154909.645460653@linuxfoundation.org> References: <20230116154909.645460653@linuxfoundation.org> User-Agent: quilt/0.67 Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Zhang Qilong [ Upstream commit 69460e68eb662064ab4188d4e129ff31c1f23ed9 ] 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: 984aa6dbf4ca ("OMAP3: PM: Adding smartreflex driver support.") Signed-off-by: Zhang Qilong Signed-off-by: Nishanth Menon Link: https://lore.kernel.org/r/20221108080322.52268-3-zhangqilong3@huawei.com Signed-off-by: Sasha Levin --- drivers/power/avs/smartreflex.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/power/avs/smartreflex.c b/drivers/power/avs/smartreflex.c index 4684e7df833a..2365efe2dae1 100644 --- a/drivers/power/avs/smartreflex.c +++ b/drivers/power/avs/smartreflex.c @@ -942,6 +942,7 @@ static int omap_sr_probe(struct platform_device *pdev) err_debugfs: debugfs_remove_recursive(sr_info->dbg_dir); err_list_del: + pm_runtime_disable(&pdev->dev); list_del(&sr_info->node); pm_runtime_put_sync(&pdev->dev); -- 2.35.1