power: supply: cpcap-charger: Simplify things with enable and disable
authorTony Lindgren <tony@atomide.com>
Sun, 10 Jan 2021 19:53:56 +0000 (21:53 +0200)
committerSebastian Reichel <sre@kernel.org>
Thu, 14 Jan 2021 22:42:42 +0000 (23:42 +0100)
commit6ddcec581fdc1b9026dd1996b9f8b834c11d868f
tree5c9b91580748a74256601e2d8cb7ffb2c0132982
parent5a21489207a52f825458d0c190bfca06e36f17e0
power: supply: cpcap-charger: Simplify things with enable and disable

Let's turn cpcap_charger_set_state() into separate cpcap_charger_enable()
and cpcap_charger_disable() to simplify things, and to allow managing
status separately. This can be then used for the follow-up patches to
make battery full status behave a bit nicer.

Cc: Arthur Demchenkov <spinal.by@gmail.com>
Cc: Carl Philipp Klemm <philipp@uvos.xyz>
Cc: Merlijn Wajer <merlijn@wizzup.org>
Cc: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/cpcap-charger.c