From 2c0ee0ec5185ecbe39ca6d3c1c61763a96e05eb4 Mon Sep 17 00:00:00 2001 From: Mark Salyzyn Date: Mon, 24 Feb 2020 14:40:49 -0800 Subject: [PATCH] ANDROID: GKI: power: power_supply: Add FG_RESET power supply property Add a new power-supply property (POWER_SUPPLY_PROP_FG_RESET) to to reset FG/QG. Signed-off-by: Anirudh Ghayal (cherry picked from commit 37f8e3dcdedcc3e38a91617193c8cfedaa8575fd) Signed-off-by: Mark Salyzyn Bug: 150789066 Change-Id: Id3bf1ab5740a064d6ce7e42ff499839dbb457b17 --- drivers/power/supply/power_supply_sysfs.c | 1 + include/linux/power_supply.h | 1 + 2 files changed, 2 insertions(+) diff --git a/drivers/power/supply/power_supply_sysfs.c b/drivers/power/supply/power_supply_sysfs.c index bf1a41d02ecc..a37a18916d5b 100644 --- a/drivers/power/supply/power_supply_sysfs.c +++ b/drivers/power/supply/power_supply_sysfs.c @@ -447,6 +447,7 @@ static struct device_attribute power_supply_attrs[] = { POWER_SUPPLY_ATTR(fcc_stepper_enable), POWER_SUPPLY_ATTR(toggle_stat), POWER_SUPPLY_ATTR(main_fcc_max), + POWER_SUPPLY_ATTR(fg_reset), /* Charge pump properties */ POWER_SUPPLY_ATTR(cp_status1), POWER_SUPPLY_ATTR(cp_status2), diff --git a/include/linux/power_supply.h b/include/linux/power_supply.h index 8210bab64394..67347792d592 100644 --- a/include/linux/power_supply.h +++ b/include/linux/power_supply.h @@ -313,6 +313,7 @@ enum power_supply_property { POWER_SUPPLY_PROP_FCC_STEPPER_ENABLE, POWER_SUPPLY_PROP_TOGGLE_STAT, POWER_SUPPLY_PROP_MAIN_FCC_MAX, + POWER_SUPPLY_PROP_FG_RESET, /* Charge pump properties */ POWER_SUPPLY_PROP_CP_STATUS1, POWER_SUPPLY_PROP_CP_STATUS2,