summaryrefslogtreecommitdiffstats
path: root/drivers/media/i2c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab2014-09-03 20:28:27 +0200
committerMauro Carvalho Chehab2014-09-03 22:59:24 +0200
commitafb666d1e7b0af5ec8f8b35b6f9d813d538c95e3 (patch)
tree5248e3653a766f7be7beb5de3f93b2b864a5b52f /drivers/media/i2c
parent[media] drxk_hard: simplify test logic (diff)
downloadkernel-qcow2-linux-afb666d1e7b0af5ec8f8b35b6f9d813d538c95e3.tar.gz
kernel-qcow2-linux-afb666d1e7b0af5ec8f8b35b6f9d813d538c95e3.tar.xz
kernel-qcow2-linux-afb666d1e7b0af5ec8f8b35b6f9d813d538c95e3.zip
[media] lm3560: simplify boolean tests
Instead of using if (on == true), just use if (on). That allows a faster mental parsing when analyzing the code. Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/i2c')
-rw-r--r--drivers/media/i2c/lm3560.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/i2c/lm3560.c b/drivers/media/i2c/lm3560.c
index c23de593c17d..d9ece4b2d047 100644
--- a/drivers/media/i2c/lm3560.c
+++ b/drivers/media/i2c/lm3560.c
@@ -100,14 +100,14 @@ static int lm3560_enable_ctrl(struct lm3560_flash *flash,
int rval;
if (led_no == LM3560_LED0) {
- if (on == true)
+ if (on)
rval = regmap_update_bits(flash->regmap,
REG_ENABLE, 0x08, 0x08);
else
rval = regmap_update_bits(flash->regmap,
REG_ENABLE, 0x08, 0x00);
} else {
- if (on == true)
+ if (on)
rval = regmap_update_bits(flash->regmap,
REG_ENABLE, 0x10, 0x10);
else