summaryrefslogtreecommitdiff
path: root/common/charger.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/charger.c')
-rw-r--r--common/charger.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/common/charger.c b/common/charger.c
index 4037af9854..741f34f9d5 100644
--- a/common/charger.c
+++ b/common/charger.c
@@ -440,6 +440,9 @@ enum ec_error_list charger_discharge_on_ac(int enable)
int chgnum;
int rv = EC_ERROR_UNIMPLEMENTED;
+ if (IS_ENABLED(CONFIG_CHARGER_DISCHARGE_ON_AC_CUSTOM))
+ return board_discharge_on_ac(enable);
+
/*
* When discharge on AC is selected, cycle through all chargers to
* enable or disable this feature.