summaryrefslogtreecommitdiff
path: root/common/charge_state_v2.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/charge_state_v2.c')
-rw-r--r--common/charge_state_v2.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/common/charge_state_v2.c b/common/charge_state_v2.c
index bd4bb81558..be0ac08cf3 100644
--- a/common/charge_state_v2.c
+++ b/common/charge_state_v2.c
@@ -2006,6 +2006,10 @@ int charge_prevent_power_on(int power_button_pressed)
defined(CONFIG_CHARGER_MIN_BAT_PCT_FOR_POWER_ON_WITH_AC)
else if (charge_manager_get_power_limit_uw() >=
CONFIG_CHARGER_MIN_POWER_MW_FOR_POWER_ON_WITH_BATT * 1000
+#ifdef CONFIG_BATTERY_REVIVE_DISCONNECT
+ && battery_get_disconnect_state() ==
+ BATTERY_NOT_DISCONNECTED
+#endif
&& (current_batt_params->state_of_charge >=
CONFIG_CHARGER_MIN_BAT_PCT_FOR_POWER_ON_WITH_AC))
prevent_power_on = 0;