Skip to content

Commit

Permalink
iio: Don't compare boolean values to true/false
Browse files Browse the repository at this point in the history
Fixes the following warnings from coccicheck:
	drivers/iio/inkern.c:81:6-14: WARNING: Comparison to bool
	drivers/iio/dac/ad5686.c:191:5-11: 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 6c724cb commit 7737fa6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion drivers/iio/dac/ad5686.c
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ static ssize_t ad5686_write_dac_powerdown(struct iio_dev *indio_dev,
if (ret)
return ret;

if (readin == true)
if (readin)
st->pwr_down_mask |= (0x3 << (chan->channel * 2));
else
st->pwr_down_mask &= ~(0x3 << (chan->channel * 2));
Expand Down
2 changes: 1 addition & 1 deletion drivers/iio/inkern.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ int iio_map_array_unregister(struct iio_dev *indio_dev,
found_it = true;
break;
}
if (found_it == false) {
if (!found_it) {
ret = -ENODEV;
goto error_ret;
}
Expand Down

0 comments on commit 7737fa6

Please sign in to comment.