summaryrefslogtreecommitdiff
path: root/common/battery.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/battery.c')
-rw-r--r--common/battery.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/common/battery.c b/common/battery.c
index f048a1db91..50d689f0d1 100644
--- a/common/battery.c
+++ b/common/battery.c
@@ -22,7 +22,6 @@
#define CPRINTS(format, args...) cprints(CC_CHARGER, format, ## args)
/* See config.h for details */
-const static int batt_full_factor = CONFIG_BATT_FULL_FACTOR;
const static int batt_host_full_factor = CONFIG_BATT_HOST_FULL_FACTOR;
const static int batt_host_shutdown_pct = CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE;
@@ -588,9 +587,6 @@ void battery_compensate_params(struct batt_params *batt)
return;
/* Some batteries don't update full capacity as often. */
- if (!IS_ENABLED(CONFIG_BATTERY_EXPORT_DISPLAY_SOC))
- /* full_factor is effectively disabled in powerd. */
- *full = *full * batt_full_factor / 100;
if (*remain > *full)
*remain = *full;
@@ -625,7 +621,7 @@ void battery_compensate_params(struct batt_params *batt)
batt->display_charge = 1000;
}
-#ifdef CONFIG_BATTERY_EXPORT_DISPLAY_SOC
+#ifdef CONFIG_CHARGER
static int battery_display_soc(struct host_cmd_handler_args *args)
{
struct ec_response_display_soc *r = args->response;