mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 31/33] staging: comedi: cb_das16_cs: use the BIP_RANGE helper macro
@ 2012-06-26  0:22 H Hartley Sweeten
  0 siblings, 0 replies; only message in thread
From: H Hartley Sweeten @ 2012-06-26  0:22 UTC (permalink / raw)
  To: Linux Kernel; +Cc: devel, abbotti, fmhess, gregkh

The BIP_RANGE(a) macro can be used instead of the RANGE(a,b)
macro when -a == b. And it's a bit clearer that this is a bipolar
range.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Cc: Frank Mori Hess <fmhess@users.sourceforge.net>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 drivers/staging/comedi/drivers/cb_das16_cs.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)

diff --git a/drivers/staging/comedi/drivers/cb_das16_cs.c b/drivers/staging/comedi/drivers/cb_das16_cs.c
index 68e6436..0d303d1 100644
--- a/drivers/staging/comedi/drivers/cb_das16_cs.c
+++ b/drivers/staging/comedi/drivers/cb_das16_cs.c
@@ -90,12 +90,13 @@ struct das16cs_private {
 
 static struct pcmcia_device *cur_dev;
 
-static const struct comedi_lrange das16cs_ai_range = { 4, {
-							   RANGE(-10, 10),
-							   RANGE(-5, 5),
-							   RANGE(-2.5, 2.5),
-							   RANGE(-1.25, 1.25),
-							   }
+static const struct comedi_lrange das16cs_ai_range = {
+	4, {
+		BIP_RANGE(10),
+		BIP_RANGE(5),
+		BIP_RANGE(2.5),
+		BIP_RANGE(1.25),
+	}
 };
 
 static irqreturn_t das16cs_interrupt(int irq, void *d)
-- 
1.7.11


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2012-06-26  0:22 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-06-26  0:22 [PATCH 31/33] staging: comedi: cb_das16_cs: use the BIP_RANGE helper macro H Hartley Sweeten

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®