linux-arm-msm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Daniel K." <dk@syse.no>
To: Julia Lawall <julia.lawall@lip6.fr>, Sinan Kaya <okaya@codeaurora.org>
Cc: linux-arm-kernel@lists.infradead.org,
	Mark Rutland <mark.rutland@arm.com>,
	Pawel Moll <pawel.moll@arm.com>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	Vinod Koul <vinod.koul@intel.com>,
	jcm@redhat.com, timur@codeaurora.org,
	Kumar Gala <galak@codeaurora.org>,
	linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
	Rob Herring <robh+dt@kernel.org>,
	cov@codeaurora.org, agross@codeaurora.org,
	dmaengine@vger.kernel.org,
	Dan Williams <dan.j.williams@intel.com>,
	linux-arm-msm@vger.kernel.org, kbuild-all@01.org
Subject: Re: [PATCH] dma: fix returnvar.cocci warnings
Date: Sun, 08 Nov 2015 21:39:29 +0000	[thread overview]
Message-ID: <563FC111.4060308@syse.no> (raw)
In-Reply-To: <alpine.DEB.2.10.1511080843100.2637@hadrien>

On 11/08/2015 07:45 AM, Julia Lawall wrote:
>  Remove unneeded variable used to store return value.
> 
> --- a/drivers/dma/qcom/hidma_ll.c
> +++ b/drivers/dma/qcom/hidma_ll.c
> @@ -567,14 +567,13 @@ int hidma_ll_resume(struct hidma_lldev *
> 
>  static int hidma_ll_hw_start(struct hidma_lldev *lldev)
>  {
> -	int rc = 0;
>  	unsigned long irqflags;
> 
>  	spin_lock_irqsave(&lldev->lock, irqflags);
>  	writel(lldev->tre_write_offset, lldev->trca + TRCA_DOORBELL_OFFSET);
>  	spin_unlock_irqrestore(&lldev->lock, irqflags);
> 
> -	return rc;
> +	return 0;
>  }
> 
>  bool hidma_ll_isenabled(struct hidma_lldev *lldev)

Seems rather pointless, what about 'static void ...' and dropping the
return statement?


Daniel K.

  parent reply	other threads:[~2015-11-08 21:39 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-08  7:45 [PATCH] dma: fix returnvar.cocci warnings Julia Lawall
2015-11-08 21:15 ` Andy Shevchenko
2015-11-08 21:17   ` Julia Lawall
2015-11-08 21:19   ` Julia Lawall
2015-11-08 21:19   ` Timur Tabi
2015-11-08 21:39 ` Daniel K. [this message]
2015-11-08 22:00   ` Sinan Kaya

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=563FC111.4060308@syse.no \
    --to=dk@syse.no \
    --cc=agross@codeaurora.org \
    --cc=cov@codeaurora.org \
    --cc=dan.j.williams@intel.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dmaengine@vger.kernel.org \
    --cc=galak@codeaurora.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=jcm@redhat.com \
    --cc=julia.lawall@lip6.fr \
    --cc=kbuild-all@01.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=okaya@codeaurora.org \
    --cc=pawel.moll@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=timur@codeaurora.org \
    --cc=vinod.koul@intel.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).