regulator: tps65219: Fix is_enabled checking in tps65219_set_bypass
authorAxel Lin <axel.lin@ingics.com>
Mon, 19 Sep 2022 12:23:53 +0000 (20:23 +0800)
committerMark Brown <broonie@kernel.org>
Mon, 26 Sep 2022 15:10:33 +0000 (16:10 +0100)
commit947934e389f716d505a656d04388b2ecbe43281d
tree90fd5aa56673a12cc1135bd595d8f2545104110b
parent21c93a95553d0a07091ff9894f09f5bffbfd8c8a
regulator: tps65219: Fix is_enabled checking in tps65219_set_bypass

Testing .enable cannot tell if a regulator is enabled or not, check return
value of .is_enabled() instead.
Also remove unneeded ret variable.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Link: https://lore.kernel.org/r/20220919122353.384171-1-axel.lin@ingics.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/tps65219-regulator.c