From: Bjorn Andersson <andersson@kernel.org>
To: Sarannya S <quic_sarannya@quicinc.com>
Cc: quic_bjorande@quicinc.com, arnaud.pouliquen@foss.st.com,
swboyd@chromium.org, quic_clew@quicinc.com,
mathieu.poirier@linaro.org, linux-kernel@vger.kernel.org,
linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org,
Deepak Kumar Singh <quic_deesin@quicinc.com>
Subject: Re: [PATCH V6 3/3] rpmsg: char: Add RPMSG GET/SET FLOWCONTROL IOCTL support
Date: Thu, 20 Apr 2023 11:38:11 -0700 [thread overview]
Message-ID: <20230420183811.oujn5eqsnqug3u4a@ripper> (raw)
In-Reply-To: <1681971690-28858-4-git-send-email-quic_sarannya@quicinc.com>
On Thu, Apr 20, 2023 at 11:51:29AM +0530, Sarannya S wrote:
> diff --git a/drivers/rpmsg/rpmsg_char.c b/drivers/rpmsg/rpmsg_char.c
[..]
> @@ -297,14 +317,31 @@ static long rpmsg_eptdev_ioctl(struct file *fp, unsigned int cmd,
> {
> struct rpmsg_eptdev *eptdev = fp->private_data;
>
> - if (cmd != RPMSG_DESTROY_EPT_IOCTL)
> - return -EINVAL;
> + bool set;
> + int ret;
>
> - /* Don't allow to destroy a default endpoint. */
> - if (eptdev->default_ept)
> - return -EINVAL;
> + switch (cmd) {
> + case RPMSG_GET_OUTGOING_FLOWCONTROL:
> + eptdev->remote_flow_updated = false;
> + ret = put_user(eptdev->remote_flow, (int __user *)arg);
> + break;
> + case RPMSG_SET_INCOMING_FLOWCONTROL:
> + set = !!arg;
> + ret = rpmsg_set_flow_control(eptdev->ept, set, 0);
The last parameter should be eptdev->chinfo.dst.
Regards,
Bjorn
next prev parent reply other threads:[~2023-04-20 18:36 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-20 6:21 [PATCH V6 0/3] rpmsg signaling/flowcontrol patches Sarannya S
2023-04-20 6:21 ` [PATCH V6 1/3] rpmsg: core: Add signal API support Sarannya S
2023-04-20 6:21 ` [PATCH V6 2/3] rpmsg: glink: Add support to handle signals command Sarannya S
2023-04-20 6:21 ` [PATCH V6 3/3] rpmsg: char: Add RPMSG GET/SET FLOWCONTROL IOCTL support Sarannya S
2023-04-20 18:38 ` Bjorn Andersson [this message]
2023-04-20 7:10 ` [PATCH V6 0/3] rpmsg signaling/flowcontrol patches Arnaud POULIQUEN
2023-04-20 7:12 ` Mukesh Ojha
2023-04-20 15:41 ` Mathieu Poirier
-- strict thread matches above, loose matches on Subject: below --
2023-04-19 13:53 Sarannya S
2023-04-19 13:53 ` [PATCH V6 3/3] rpmsg: char: Add RPMSG GET/SET FLOWCONTROL IOCTL support Sarannya S
2023-04-19 17:03 ` 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=20230420183811.oujn5eqsnqug3u4a@ripper \
--to=andersson@kernel.org \
--cc=arnaud.pouliquen@foss.st.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-remoteproc@vger.kernel.org \
--cc=mathieu.poirier@linaro.org \
--cc=quic_bjorande@quicinc.com \
--cc=quic_clew@quicinc.com \
--cc=quic_deesin@quicinc.com \
--cc=quic_sarannya@quicinc.com \
--cc=swboyd@chromium.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