Skip to content

Commit

Permalink
staging:iio: Don't compare boolean values with true/false
Browse files Browse the repository at this point in the history
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>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
  • Loading branch information
Lars-Peter Clausen authored and Jonathan Cameron committed Oct 19, 2012
1 parent cdf71c7 commit 6fae58f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion drivers/staging/iio/accel/lis3l02dq_ring.c
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/iio/iio_dummy_evgen.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 6fae58f

Please sign in to comment.