All of lore.kernel.org
 help / color / mirror / Atom feed
From: Miaoqian Lin <linmq006@gmail.com>
Cc: linmq006@gmail.com, Kishon Vijay Abraham I <kishon@ti.com>,
	Vinod Koul <vkoul@kernel.org>, Tony Lindgren <tony@atomide.com>,
	linux-phy@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH] phy: mapphone-mdm6600: Fix PM disable depth imbalance in phy_mdm6600_probe
Date: Wed,  5 Jan 2022 12:39:42 +0000	[thread overview]
Message-ID: <20220105123947.17946-1-linmq006@gmail.com> (raw)

The pm_runtime_enable will increase power disable depth.
If the probe fails, we should use pm_runtime_disable() to balance
pm_runtime_enable().

Fixes: f7f50b2 ("phy: mapphone-mdm6600: Add runtime PM support for n_gsm on USB suspend")
Signed-off-by: Miaoqian Lin <linmq006@gmail.com>
---
 drivers/phy/motorola/phy-mapphone-mdm6600.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/phy/motorola/phy-mapphone-mdm6600.c b/drivers/phy/motorola/phy-mapphone-mdm6600.c
index 5172971f4c36..14666750946c 100644
--- a/drivers/phy/motorola/phy-mapphone-mdm6600.c
+++ b/drivers/phy/motorola/phy-mapphone-mdm6600.c
@@ -630,6 +630,9 @@ static int phy_mdm6600_probe(struct platform_device *pdev)
 	if (error < 0)
 		phy_mdm6600_device_power_off(ddata);
 
+disable_pm:
+	pm_runtime_disable(ddata->dev);
+
 	return error;
 }
 
-- 
2.17.1


-- 
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy

WARNING: multiple messages have this Message-ID (diff)
From: Miaoqian Lin <linmq006@gmail.com>
To: unlisted-recipients:; (no To-header on input)
Cc: linmq006@gmail.com, Kishon Vijay Abraham I <kishon@ti.com>,
	Vinod Koul <vkoul@kernel.org>, Tony Lindgren <tony@atomide.com>,
	linux-phy@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH] phy: mapphone-mdm6600: Fix PM disable depth imbalance in phy_mdm6600_probe
Date: Wed,  5 Jan 2022 12:39:42 +0000	[thread overview]
Message-ID: <20220105123947.17946-1-linmq006@gmail.com> (raw)

The pm_runtime_enable will increase power disable depth.
If the probe fails, we should use pm_runtime_disable() to balance
pm_runtime_enable().

Fixes: f7f50b2 ("phy: mapphone-mdm6600: Add runtime PM support for n_gsm on USB suspend")
Signed-off-by: Miaoqian Lin <linmq006@gmail.com>
---
 drivers/phy/motorola/phy-mapphone-mdm6600.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/phy/motorola/phy-mapphone-mdm6600.c b/drivers/phy/motorola/phy-mapphone-mdm6600.c
index 5172971f4c36..14666750946c 100644
--- a/drivers/phy/motorola/phy-mapphone-mdm6600.c
+++ b/drivers/phy/motorola/phy-mapphone-mdm6600.c
@@ -630,6 +630,9 @@ static int phy_mdm6600_probe(struct platform_device *pdev)
 	if (error < 0)
 		phy_mdm6600_device_power_off(ddata);
 
+disable_pm:
+	pm_runtime_disable(ddata->dev);
+
 	return error;
 }
 
-- 
2.17.1


             reply	other threads:[~2022-01-05 12:39 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-05 12:39 Miaoqian Lin [this message]
2022-01-05 12:39 ` [PATCH] phy: mapphone-mdm6600: Fix PM disable depth imbalance in phy_mdm6600_probe Miaoqian Lin
2022-01-05 18:41 ` kernel test robot
2022-01-05 18:41   ` kernel test robot
2022-01-05 18:41   ` kernel test robot
2022-03-01  2:46 ` [PATCH v2] phy: mapphone-mdm6600: Fix PM error handling " Miaoqian Lin
2022-03-01  2:46   ` Miaoqian Lin
2022-04-13 10:54   ` Vinod Koul
2022-04-13 10:54     ` Vinod Koul
  -- strict thread matches above, loose matches on Subject: below --
2022-01-07 10:01 [PATCH] phy: mapphone-mdm6600: Fix PM disable depth imbalance " kernel test robot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220105123947.17946-1-linmq006@gmail.com \
    --to=linmq006@gmail.com \
    --cc=kishon@ti.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-phy@lists.infradead.org \
    --cc=tony@atomide.com \
    --cc=vkoul@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.