linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] staging:iio: Don't compare boolean values with true/false
@ 2012-10-18 14:43 Lars-Peter Clausen
  2012-10-18 14:43 ` [PATCH 2/4] staging:iio:lpc32xx_adc: Use resource_size instead of opencoding it Lars-Peter Clausen
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: Lars-Peter Clausen @ 2012-10-18 14:43 UTC (permalink / raw)
  To: Jonathan Cameron; +Cc: linux-iio, Lars-Peter Clausen

Fixes the following coccicheck warnings:
	drivers/staging/iio/accel/lis3l02dq_ring.c:240:5-10: WARNING: Comparison to bool
	drivers/staging/iio/iio_dummy_evgen.c:111:6-25: WARNING: Comparison to bool

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 drivers/staging/iio/accel/lis3l02dq_ring.c |    2 +-
 drivers/staging/iio/iio_dummy_evgen.c      |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/iio/accel/lis3l02dq_ring.c b/drivers/staging/iio/accel/lis3l02dq_ring.c
index fa4190d..ee887e9 100644
--- a/drivers/staging/iio/accel/lis3l02dq_ring.c
+++ b/drivers/staging/iio/accel/lis3l02dq_ring.c
@@ -237,7 +237,7 @@ static int lis3l02dq_data_rdy_trigger_set_state(struct iio_trigger *trig,
 	u8 t;
 
 	__lis3l02dq_write_data_ready_config(indio_dev, state);
-	if (state == false) {
+	if (!state) {
 		/*
 		 * A possible quirk with the handler is currently worked around
 		 * by ensuring outstanding read events are cleared.
diff --git a/drivers/staging/iio/iio_dummy_evgen.c b/drivers/staging/iio/iio_dummy_evgen.c
index 74e24e8..132d278 100644
--- a/drivers/staging/iio/iio_dummy_evgen.c
+++ b/drivers/staging/iio/iio_dummy_evgen.c
@@ -108,7 +108,7 @@ int iio_dummy_evgen_get_irq(void)
 
 	mutex_lock(&iio_evgen->lock);
 	for (i = 0; i < IIO_EVENTGEN_NO; i++)
-		if (iio_evgen->inuse[i] == false) {
+		if (!iio_evgen->inuse[i]) {
 			ret = iio_evgen->base + i;
 			iio_evgen->inuse[i] = true;
 			break;
-- 
1.7.10.4


^ permalink raw reply related	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2012-10-19 17:59 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-18 14:43 [PATCH 1/4] staging:iio: Don't compare boolean values with true/false Lars-Peter Clausen
2012-10-18 14:43 ` [PATCH 2/4] staging:iio:lpc32xx_adc: Use resource_size instead of opencoding it Lars-Peter Clausen
2012-10-18 16:16   ` Roland Stigge
2012-10-19 15:26     ` Jonathan Cameron
2012-10-18 14:43 ` [PATCH 3/4] iio: Don't compare boolean values to true/false Lars-Peter Clausen
2012-10-19 15:27   ` Jonathan Cameron
2012-10-18 14:43 ` [PATCH 4/4] iio: at91_adc: Use devm_kcalloc to allocate arrays Lars-Peter Clausen
2012-10-19  8:54   ` Maxime Ripard
2012-10-19 15:32   ` Jonathan Cameron
2012-10-19 15:24 ` [PATCH 1/4] staging:iio: Don't compare boolean values with true/false Jonathan Cameron
2012-10-19 17:55   ` Lars-Peter Clausen
2012-10-19 17:59     ` Jonathan Cameron

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).