From af7ccad898330cdc602209633bcefcf1f1b5f2cf Mon Sep 17 00:00:00 2001 From: Daisuke Nojiri Date: Tue, 29 Jun 2021 11:15:55 -0700 Subject: battery: Set host's low battery shutdown SoC to 4% Currently, the host's low battery shutdown SoC is 3% by default but most boards are configured to 4%. This patch changes the default value to 4% so that we require only minority boards to customize it. BUG=b:191837893, b:189737806 BRANCH=None TEST=Storo using battfake EC command. Change-Id: I69ed5d8cc8c0d1e321d79c5eae26a9c21624a4ea Signed-off-by: Daisuke Nojiri Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2998509 Reviewed-by: Aseda Aboagye Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3340215 --- include/config.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/config.h b/include/config.h index 4e07add025..940193339b 100644 --- a/include/config.h +++ b/include/config.h @@ -489,20 +489,20 @@ * Thus, we set them as follows by default: * * CONFIG_CHARGER_MIN_BAT_PCT_FOR_POWER_ON = 2 (don't boot if soc < 2%) - * CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE = 3 (shutdown if soc <= 3%) + * CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE = 4 (shutdown if soc <= 4%) * BATTERY_LEVEL_SHUTDOWN = 3 (shutdown if soc < 3%) * * This produces the following behavior: * * - If soc = 1%, system doesn't boot. User wouldn't know why. - * - If soc = 2~3%, system boots. Alert is shown. System immediately shuts down. - * - If battery discharges to 3% while the system is running, system shuts down. + * - If soc = 2~4%, system boots. Alert is shown. System immediately shuts down. + * - If battery discharges to 4% while the system is running, system shuts down. * If that happens while a user is away, they can press the power button to * learn what happened. * - If system fails to shutdown for some reason and battery further discharges * to 2%, EC will trigger shutdown. */ -#define CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE 3 /* shutdown if soc <= 3% */ +#define CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE 4 /* shutdown if soc <= 4% */ /* * Powerd's full_factor. The value comes from: -- cgit v1.2.1