From: Chris Lew <clew@codeaurora.org>
To: bjorn.andersson@linaro.org, ohad@wizery.com
Cc: aneela@codeaurora.org, linux-arm-msm@vger.kernel.org,
linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org,
Chris Lew <clew@codeaurora.org>
Subject: [PATCH] rpmsg: glink: Remove channel decouple from rpdev release
Date: Tue, 8 Oct 2019 18:33:45 -0700 [thread overview]
Message-ID: <20191009013345.17192-1-clew@codeaurora.org> (raw)
If a channel is being rapidly restarted and the kobj release worker is
busy, there is a chance the the rpdev_release function will run after
the channel struct itself has been released.
There should not be a need to decouple the channel from rpdev in the
rpdev release since that should only happen from the channel close
commands.
Signed-off-by: Chris Lew <clew@codeaurora.org>
---
drivers/rpmsg/qcom_glink_native.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/rpmsg/qcom_glink_native.c b/drivers/rpmsg/qcom_glink_native.c
index 621f1afd4d6b..836a0bd99d11 100644
--- a/drivers/rpmsg/qcom_glink_native.c
+++ b/drivers/rpmsg/qcom_glink_native.c
@@ -1350,9 +1350,7 @@ static const struct rpmsg_endpoint_ops glink_endpoint_ops = {
static void qcom_glink_rpdev_release(struct device *dev)
{
struct rpmsg_device *rpdev = to_rpmsg_device(dev);
- struct glink_channel *channel = to_glink_channel(rpdev->ept);
- channel->rpdev = NULL;
kfree(rpdev);
}
--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project
next reply other threads:[~2019-10-09 1:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-09 1:33 Chris Lew [this message]
2019-10-10 5:04 ` [PATCH] rpmsg: glink: Remove channel decouple from rpdev release Stephen Boyd
2019-10-11 18:43 ` Chris Lew
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=20191009013345.17192-1-clew@codeaurora.org \
--to=clew@codeaurora.org \
--cc=aneela@codeaurora.org \
--cc=bjorn.andersson@linaro.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-remoteproc@vger.kernel.org \
--cc=ohad@wizery.com \
/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