From: julia.lawall@lip6.fr (Julia Lawall)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] dma: fix returnvar.cocci warnings
Date: Sun, 8 Nov 2015 08:45:26 +0100 (CET) [thread overview]
Message-ID: <alpine.DEB.2.10.1511080843100.2637@hadrien> (raw)
Remove unneeded variable used to store return value.
Generated by: scripts/coccinelle/misc/returnvar.cocci
CC: Sinan Kaya <okaya@codeaurora.org>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
---
hidma_ll.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
--- 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)
@@ -600,7 +599,6 @@ bool hidma_ll_isenabled(struct hidma_lld
int hidma_ll_queue_request(struct hidma_lldev *lldev, u32 tre_ch)
{
struct hidma_tre *tre;
- int rc = 0;
unsigned long flags;
tre = &lldev->trepool[tre_ch];
@@ -618,7 +616,7 @@ int hidma_ll_queue_request(struct hidma_
lldev->tre_write_offset = (lldev->tre_write_offset + TRE_SIZE)
% lldev->tre_ring_size;
spin_unlock_irqrestore(&lldev->lock, flags);
- return rc;
+ return 0;
}
int hidma_ll_start(struct hidma_lldev *lldev)
next reply other threads:[~2015-11-08 7:45 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-08 7:45 Julia Lawall [this message]
2015-11-08 21:15 ` [PATCH] dma: fix returnvar.cocci warnings 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.
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=alpine.DEB.2.10.1511080843100.2637@hadrien \
--to=julia.lawall@lip6.fr \
--cc=linux-arm-kernel@lists.infradead.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;
as well as URLs for NNTP newsgroup(s).