diff options
author | Tony Lindgren <[email protected]> | 2021-01-10 21:53:57 +0200 |
---|---|---|
committer | Sebastian Reichel <[email protected]> | 2021-01-14 23:42:42 +0100 |
commit | 2071236b8519673a276ecbf7f60a6f7da7e5cd8a (patch) | |
tree | b26d66e593f1d532f353b2c9751dd954907ae735 /include/linux/compiler_attributes.h | |
parent | 6ddcec581fdc1b9026dd1996b9f8b834c11d868f (diff) |
power: supply: cpcap-charger: Provide state updates for battery from charger
We want to have the battery update it's status when the charge is done,
and when the charger is disconnected. Otherwise the battery does not know
when it's full unless there's a userspace app polling the battery status.
To do this, we add supplied_to handling to cpcap-battery, and implement
power_supply_changed() for cpcap-charger. When cpcap-charger calls
power_supply_changed(), cpcap-battery will update it's status.
Let's also use new_state variable for the POWER_SUPPLY_STATUS_CHARGING
case to have unified handling for the switch.
Cc: Arthur Demchenkov <[email protected]>
Cc: Carl Philipp Klemm <[email protected]>
Cc: Merlijn Wajer <[email protected]>
Cc: Pavel Machek <[email protected]>
Signed-off-by: Tony Lindgren <[email protected]>
Signed-off-by: Sebastian Reichel <[email protected]>
Diffstat (limited to 'include/linux/compiler_attributes.h')
0 files changed, 0 insertions, 0 deletions