ANDROID: power_supply: Add POWER_SUPPLY_CHARGE_TYPE_TAPER

Used to track the constant voltage phase of charging and implement
tier transition for multi-step charging.

Bug: 168244640
Signed-off-by: AleX Pelosi <apelosi@google.com>
Change-Id: I49d3033eec671156ffd113d8d0e3972d2cdad982
This commit is contained in:
AleX Pelosi 2020-08-27 11:00:04 -07:00
parent 23516028ff
commit 15d1929781
2 changed files with 7 additions and 0 deletions

View File

@ -88,6 +88,7 @@ static const char * const POWER_SUPPLY_CHARGE_TYPE_TEXT[] = {
[POWER_SUPPLY_CHARGE_TYPE_ADAPTIVE] = "Adaptive",
[POWER_SUPPLY_CHARGE_TYPE_CUSTOM] = "Custom",
[POWER_SUPPLY_CHARGE_TYPE_LONGLIFE] = "Long Life",
[POWER_SUPPLY_CHARGE_TYPE_TAPER] = "Taper",
};
static const char * const POWER_SUPPLY_HEALTH_TEXT[] = {

View File

@ -49,6 +49,12 @@ enum {
POWER_SUPPLY_CHARGE_TYPE_ADAPTIVE, /* dynamically adjusted speed */
POWER_SUPPLY_CHARGE_TYPE_CUSTOM, /* use CHARGE_CONTROL_* props */
POWER_SUPPLY_CHARGE_TYPE_LONGLIFE, /* slow speed, longer life */
/*
* force to 50 to minimize the chances of userspace binary
* incompatibility on newer upstream kernels
*/
POWER_SUPPLY_CHARGE_TYPE_TAPER = 50, /* charging in CV phase */
};
enum {