public inbox for linux-remoteproc@vger.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Vasyl Gomonovych <gomonovych@gmail.com>
Cc: ohad@wizery.com, linux-remoteproc@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] remoteproc: qcom: Use PTR_ERR_OR_ZERO() in glink prob
Date: Tue, 28 Nov 2017 15:02:58 -0800	[thread overview]
Message-ID: <20171128230258.GA17344@builder> (raw)
In-Reply-To: <1511908360-7712-1-git-send-email-gomonovych@gmail.com>

On Tue 28 Nov 14:32 PST 2017, Vasyl Gomonovych wrote:

> Fix ptr_ret.cocci warnings:
> drivers/remoteproc/qcom_common.c:60:8-14: WARNING: PTR_ERR_OR_ZERO can be used
> 
> Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR
> 
> Generated by: scripts/coccinelle/api/ptr_ret.cocci
> 
> Signed-off-by: Vasyl Gomonovych <gomonovych@gmail.com>

Applied.

Thanks,
Bjorn

> ---
>  drivers/remoteproc/qcom_common.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/remoteproc/qcom_common.c b/drivers/remoteproc/qcom_common.c
> index d487040b528b..e9b5f2a98c4d 100644
> --- a/drivers/remoteproc/qcom_common.c
> +++ b/drivers/remoteproc/qcom_common.c
> @@ -57,7 +57,7 @@ static int glink_subdev_probe(struct rproc_subdev *subdev)
>  
>  	glink->edge = qcom_glink_smem_register(glink->dev, glink->node);
>  
> -	return IS_ERR(glink->edge) ? PTR_ERR(glink->edge) : 0;
> +	return PTR_ERR_OR_ZERO(glink->edge);
>  }
>  
>  static void glink_subdev_remove(struct rproc_subdev *subdev)
> -- 
> 1.9.1
> 

      reply	other threads:[~2017-11-28 23:02 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-28 22:32 [PATCH] remoteproc: qcom: Use PTR_ERR_OR_ZERO() in glink prob Vasyl Gomonovych
2017-11-28 23:02 ` Bjorn Andersson [this message]

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=20171128230258.GA17344@builder \
    --to=bjorn.andersson@linaro.org \
    --cc=gomonovych@gmail.com \
    --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