From: zhengbin <zhengbin13@huawei.com>
To: <gregkh@linuxfoundation.org>, <eric@anholt.net>,
<wahrenst@gmx.net>, <abbotti@mev.co.uk>,
<hsweeten@visionengravers.com>, <devel@driverdev.osuosl.org>
Cc: zhengbin13@huawei.com
Subject: [PATCH 6/6] staging: comedi: Remove set but not used variable 'aref'
Date: Tue, 8 Oct 2019 13:39:02 +0800 [thread overview]
Message-ID: <1570513142-60177-7-git-send-email-zhengbin13@huawei.com> (raw)
In-Reply-To: <1570513142-60177-1-git-send-email-zhengbin13@huawei.com>
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/staging/comedi/drivers/dt3000.c: In function dt3k_ai_insn_read:
drivers/staging/comedi/drivers/dt3000.c:511:27: warning: variable aref set but not used [-Wunused-but-set-variable]
It is not used since commit 2e310235ca8f ("staging:
comedi: dt3000: rename dt3k_ai_insn()")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: zhengbin <zhengbin13@huawei.com>
---
drivers/staging/comedi/drivers/dt3000.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/staging/comedi/drivers/dt3000.c b/drivers/staging/comedi/drivers/dt3000.c
index caf4d4d..f7c365b 100644
--- a/drivers/staging/comedi/drivers/dt3000.c
+++ b/drivers/staging/comedi/drivers/dt3000.c
@@ -508,12 +508,11 @@ static int dt3k_ai_insn_read(struct comedi_device *dev,
unsigned int *data)
{
int i;
- unsigned int chan, gain, aref;
+ unsigned int chan, gain;
chan = CR_CHAN(insn->chanspec);
gain = CR_RANGE(insn->chanspec);
/* XXX docs don't explain how to select aref */
- aref = CR_AREF(insn->chanspec);
for (i = 0; i < insn->n; i++)
data[i] = dt3k_readsingle(dev, DPR_SUBSYS_AI, chan, gain);
--
2.7.4
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
prev parent reply other threads:[~2019-10-08 5:32 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-08 5:38 [PATCH 0/6] staging: Remove a bounch set of set but not used variables zhengbin
2019-10-08 5:38 ` [PATCH 1/6] staging: bcm2835-audio: Remove set but not used variable 'status' zhengbin
2019-10-08 6:04 ` Dan Carpenter
2019-10-08 5:38 ` [PATCH 2/6] staging: sm750fb: Remove set but not used variable 'uiActualPixelClk' zhengbin
2019-10-08 6:06 ` Dan Carpenter
2019-10-08 6:08 ` Dan Carpenter
2019-10-08 5:38 ` [PATCH 3/6] staging: sm750fb: Remove set but not used variable 'actual_mx_clk' zhengbin
2019-10-08 5:39 ` [PATCH 4/6] staging: comedi: Remove set but not used variable 'data' zhengbin
2019-10-08 5:39 ` [PATCH 5/6] staging: comedi: Remove set but not used variable 'hi' zhengbin
2019-10-08 5:39 ` zhengbin [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=1570513142-60177-7-git-send-email-zhengbin13@huawei.com \
--to=zhengbin13@huawei.com \
--cc=abbotti@mev.co.uk \
--cc=devel@driverdev.osuosl.org \
--cc=eric@anholt.net \
--cc=gregkh@linuxfoundation.org \
--cc=hsweeten@visionengravers.com \
--cc=wahrenst@gmx.net \
/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).