Commit afb666d1 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

[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: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
parent 5a7f7b79
......@@ -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
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment