From: Mukesh Ojha <quic_mojha@quicinc.com>
To: <cgel.zte@gmail.com>, <bjorn.andersson@linaro.org>
Cc: <mathieu.poirier@linaro.org>, <linux-remoteproc@vger.kernel.org>,
<linux-kernel@vger.kernel.org>,
ye xingchen <ye.xingchen@zte.com.cn>,
Zeal Robot <zealci@zte.com.cn>
Subject: Re: [PATCH linux-next] rpmsg: char: Remove the unneeded result variable
Date: Fri, 26 Aug 2022 13:10:18 +0530 [thread overview]
Message-ID: <089f50b7-a87e-8570-d85f-be7470153493@quicinc.com> (raw)
In-Reply-To: <20220826071954.252485-1-ye.xingchen@zte.com.cn>
On 8/26/2022 12:49 PM, cgel.zte@gmail.com wrote:
> From: ye xingchen <ye.xingchen@zte.com.cn>
>
> Return the value rpmsg_chrdev_eptdev_add() directly instead of storing it
> in another redundant variable.
>
> Reported-by: Zeal Robot <zealci@zte.com.cn>
> Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn>
> ---
> drivers/rpmsg/rpmsg_char.c | 5 +----
> 1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/drivers/rpmsg/rpmsg_char.c b/drivers/rpmsg/rpmsg_char.c
> index 4f2189111494..0850ae34fb88 100644
> --- a/drivers/rpmsg/rpmsg_char.c
> +++ b/drivers/rpmsg/rpmsg_char.c
> @@ -424,15 +424,12 @@ int rpmsg_chrdev_eptdev_create(struct rpmsg_device *rpdev, struct device *parent
> struct rpmsg_channel_info chinfo)
> {
> struct rpmsg_eptdev *eptdev;
> - int ret;
>
> eptdev = rpmsg_chrdev_eptdev_alloc(rpdev, parent);
> if (IS_ERR(eptdev))
> return PTR_ERR(eptdev);
>
> - ret = rpmsg_chrdev_eptdev_add(eptdev, chinfo);
> -
> - return ret;
> + return rpmsg_chrdev_eptdev_add(eptdev, chinfo);
> }
LGTM.
Reviewed-by:Mukesh Ojha <quic_mojha@quicinc.com>
-Mukesh
> EXPORT_SYMBOL(rpmsg_chrdev_eptdev_create);
>
next prev parent reply other threads:[~2022-08-26 7:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-26 7:19 cgel.zte
2022-08-26 7:40 ` Mukesh Ojha [this message]
2022-08-31 16:46 ` Mathieu Poirier
2022-09-01 5:32 ` cgel.zte
2022-09-02 19:32 ` Mathieu Poirier
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=089f50b7-a87e-8570-d85f-be7470153493@quicinc.com \
--to=quic_mojha@quicinc.com \
--cc=bjorn.andersson@linaro.org \
--cc=cgel.zte@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-remoteproc@vger.kernel.org \
--cc=mathieu.poirier@linaro.org \
--cc=ye.xingchen@zte.com.cn \
--cc=zealci@zte.com.cn \
/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®