Commit 70be1305 authored by Kim, Milo's avatar Kim, Milo Committed by Anton Vorontsov

lp8727_charger: Make lp8727_init_device() shorter

Just return with lp8727_write_byte(), no need to check its value.
Signed-off-by: default avatarMilo(Woogyom) Kim <milo.kim@ti.com>
Signed-off-by: default avatarAnton Vorontsov <anton.vorontsov@linaro.org>
parent 65272bac
......@@ -152,11 +152,7 @@ static int lp8727_init_device(struct lp8727_chg *pchg)
return ret;
val = LP8727_INT_EN | LP8727_CHGDET_EN;
ret = lp8727_write_byte(pchg, LP8727_CTRL2, val);
if (ret)
return ret;
return 0;
return lp8727_write_byte(pchg, LP8727_CTRL2, val);
}
static int lp8727_is_dedicated_charger(struct lp8727_chg *pchg)
......
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