From: Wentao Liang <vulab@iscas.ac.cn>
To: gregkh@linuxfoundation.org
Cc: linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-sound@vger.kernel.org, srini@kernel.org, vkoul@kernel.org,
Wentao Liang <vulab@iscas.ac.cn>,
stable@vger.kernel.org
Subject: [PATCH] slimbus: ngd: Fix runtime PM leak in qcom_slim_ngd_xfer_msg_sync()
Date: Thu, 17 Sep 2026 15:25:25 +0000 [thread overview]
Message-ID: <20260917152525.2160238-1-vulab@iscas.ac.cn> (raw)
The successful transfer path returns 0 without dropping the runtime PM
usage counter taken by pm_runtime_get_sync(). The error paths all jump
to pm_put, which releases the reference, but a completed transfer keeps
it forever.
Fall through to pm_put on success so the reference is always released.
Fixes: 917809e2280bb ("slimbus: ngd: Add qcom SLIMBus NGD driver")
Cc: stable@vger.kernel.org
Signed-off-by: Wentao Liang <vulab@iscas.ac.cn>
---
drivers/slimbus/qcom-ngd-ctrl.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/slimbus/qcom-ngd-ctrl.c b/drivers/slimbus/qcom-ngd-ctrl.c
index 1ed6be6e85d2..be5640f45d7c 100644
--- a/drivers/slimbus/qcom-ngd-ctrl.c
+++ b/drivers/slimbus/qcom-ngd-ctrl.c
@@ -937,7 +937,6 @@ static int qcom_slim_ngd_xfer_msg_sync(struct slim_controller *ctrl,
ret = -ETIMEDOUT;
goto pm_put;
}
- return 0;
pm_put:
pm_runtime_put(ctrl->dev);
--
2.34.1
next reply other threads:[~2026-09-17 15:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-17 15:25 Wentao Liang [this message]
2026-09-18 6:32 ` Srinivas Kandagatla
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=20260917152525.2160238-1-vulab@iscas.ac.cn \
--to=vulab@iscas.ac.cn \
--cc=gregkh@linuxfoundation.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=srini@kernel.org \
--cc=stable@vger.kernel.org \
--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 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®