* [PATCH] media: iris: Fix runtime PM imbalance in iris_enable_power_domains()
@ 2026-09-17 9:57 Wentao Liang
2026-09-21 9:04 ` Konrad Dybcio
0 siblings, 1 reply; 2+ messages in thread
From: Wentao Liang @ 2026-09-17 9:57 UTC (permalink / raw)
To: abhinav.kumar
Cc: bod, dikshita.agarwal, hverkuil, linux-arm-msm, linux-kernel,
linux-media, mchehab, stefan.schmidt, vikash.garodia,
Wentao Liang, stable
pm_runtime_get_sync() leaves the runtime PM usage count of pd_dev
incremented even when resuming the device fails, and
iris_enable_power_domains() returns immediately in that case, so
the reference is never dropped.
Roll the usage count back with pm_runtime_put_noidle() on the error
path.
Fixes: bb8a95aa038e ("media: iris: implement power management")
Cc: stable@vger.kernel.org
Signed-off-by: Wentao Liang <vulab@iscas.ac.cn>
---
drivers/media/platform/qcom/iris/iris_resources.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/media/platform/qcom/iris/iris_resources.c b/drivers/media/platform/qcom/iris/iris_resources.c
index 773f6548370a..d56bc8cc66ed 100644
--- a/drivers/media/platform/qcom/iris/iris_resources.c
+++ b/drivers/media/platform/qcom/iris/iris_resources.c
@@ -79,8 +79,10 @@ int iris_enable_power_domains(struct iris_core *core, struct device *pd_dev)
return ret;
ret = pm_runtime_get_sync(pd_dev);
- if (ret < 0)
+ if (ret < 0) {
+ pm_runtime_put_noidle(pd_dev);
return ret;
+ }
return ret;
}
--
2.34.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] media: iris: Fix runtime PM imbalance in iris_enable_power_domains()
2026-09-17 9:57 [PATCH] media: iris: Fix runtime PM imbalance in iris_enable_power_domains() Wentao Liang
@ 2026-09-21 9:04 ` Konrad Dybcio
0 siblings, 0 replies; 2+ messages in thread
From: Konrad Dybcio @ 2026-09-21 9:04 UTC (permalink / raw)
To: Wentao Liang, abhinav.kumar
Cc: bod, dikshita.agarwal, hverkuil, linux-arm-msm, linux-kernel,
linux-media, mchehab, stefan.schmidt, vikash.garodia, stable
On 9/17/26 11:57 AM, Wentao Liang wrote:
> pm_runtime_get_sync() leaves the runtime PM usage count of pd_dev
> incremented even when resuming the device fails, and
> iris_enable_power_domains() returns immediately in that case, so
> the reference is never dropped.
>
> Roll the usage count back with pm_runtime_put_noidle() on the error
> path.
>
> Fixes: bb8a95aa038e ("media: iris: implement power management")
> Cc: stable@vger.kernel.org
> Signed-off-by: Wentao Liang <vulab@iscas.ac.cn>
> ---
Already fixed in:
f87d7eda07fc ("media: qcom: iris: fix runtime PM reference leaks")
Konrad
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-09-21 9:04 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-17 9:57 [PATCH] media: iris: Fix runtime PM imbalance in iris_enable_power_domains() Wentao Liang
2026-09-21 9:04 ` Konrad Dybcio
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®