From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Loic PALLARDY <loic.pallardy@st.com>
Cc: Ohad Ben-Cohen <ohad@wizery.com>,
"linux-remoteproc@vger.kernel.org"
<linux-remoteproc@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-arm-msm@vger.kernel.org" <linux-arm-msm@vger.kernel.org>
Subject: Re: [PATCH 2/3] rpmsg: Only invoke announce_create for rpdev with endpoints
Date: Tue, 10 Apr 2018 11:27:29 -0700 [thread overview]
Message-ID: <20180410182729.GB1510@tuxbook-pro> (raw)
In-Reply-To: <3c952b4ca0cc4666ba01cf0dbe605248@SFHDAG7NODE2.st.com>
On Tue 03 Apr 02:12 PDT 2018, Loic PALLARDY wrote:
> > -----Original Message-----
> > From: linux-remoteproc-owner@vger.kernel.org [mailto:linux-remoteproc-
> > owner@vger.kernel.org] On Behalf Of Bjorn Andersson
[..]
> > diff --git a/drivers/rpmsg/rpmsg_core.c b/drivers/rpmsg/rpmsg_core.c
> > index dffa3aab7178..e85d2691d2cf 100644
> > --- a/drivers/rpmsg/rpmsg_core.c
> > +++ b/drivers/rpmsg/rpmsg_core.c
> > @@ -442,7 +442,7 @@ static int rpmsg_dev_probe(struct device *dev)
> > goto out;
> > }
> >
> > - if (rpdev->ops->announce_create)
> > + if (ept && rpdev->ops->announce_create)
>
> This check is already part of virtio_rpmsg.c (see line 341)
> /* need to tell remote processor's name service about this channel ? */
> if (rpdev->announce && rpdev->ept &&
> virtio_has_feature(vrp->vdev, VIRTIO_RPMSG_F_NS)) {
The introduction of rpdev->ept in this check was done by Henri, as he
was implementing rpmsg_char support for virtio_rpmsg:
b2599ebffb2d ("rpmsg: virtio_rpmsg_bus: fix announce for devices without endpoint")
It's there because the rpmsg_device will not have a primary endpoint and
as such there's no communication channel to announce. We could add this
check in each implementation of announce, but I think it's a common
issue.
>
> should it be part of qcom_smd driver too? (but each implementation will duplicate checks)
> Or may have a generic check in the core including rpdev->announce as well (and doing virtio_rpmsg.c clean-up)
>
I think we want to remove the ept check in virtio_rpmsg, to reduce that
part of the duplication at least.
> Change will become:
> if (rpdev->announce && ept && rpdev->ops->announce_create)
>
That might make sense, let's see what Wendy comes up with related to
rpmsg_char and supporting Linux-side services, as I suspect that this
handling might be affected.
Regards,
Bjorn
next prev parent reply other threads:[~2018-04-10 18:26 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-27 21:06 [PATCH 0/3] rpmsg: smd: Redeliver messages after probe Bjorn Andersson
2018-03-27 21:06 ` [PATCH 1/3] rpmsg: smd: Fix container_of macros Bjorn Andersson
2018-03-27 21:06 ` [PATCH 2/3] rpmsg: Only invoke announce_create for rpdev with endpoints Bjorn Andersson
2018-04-03 9:12 ` Loic PALLARDY
2018-04-10 18:27 ` Bjorn Andersson [this message]
2018-04-10 8:22 ` Loic PALLARDY
2018-03-27 21:06 ` [PATCH 3/3] rpmsg: smd: Use announce_create to process any receive work Bjorn Andersson
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=20180410182729.GB1510@tuxbook-pro \
--to=bjorn.andersson@linaro.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-remoteproc@vger.kernel.org \
--cc=loic.pallardy@st.com \
--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;
as well as URLs for NNTP newsgroup(s).