summaryrefslogtreecommitdiff
path: root/board/storo/board.h
diff options
context:
space:
mode:
authorDaisuke Nojiri <dnojiri@chromium.org>2021-06-22 21:24:06 -0700
committerCommit Bot <commit-bot@chromium.org>2021-06-23 20:47:18 +0000
commit3aa4dd2c4a695152dd17aaec601d3a79bc5ab1c4 (patch)
tree0f08d695a03d2ca88092b7ae82429cd38143928e /board/storo/board.h
parent87f59b57817d5800fd929938b2dca914bad14d2c (diff)
downloadchrome-ec-3aa4dd2c4a695152dd17aaec601d3a79bc5ab1c4.tar.gz
chgstv2: Unify power-on and shutdown battery thresholds
Currently, power-on battery SoC and shutdown battery SoC are independently configured by each board. This patch will unify the setting as follows: CONFIG_CHARGER_MIN_BAT_PCT_FOR_POWER_ON = 2 (don't boot if soc < 2%) CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE = 2 (shutdown if soc <= 2%) BATTERY_LEVEL_SHUTDOWN = 3 (shutdown if soc < 3%) CONFIG_BATTERY_EXPORT_DISPLAY_SOC = Y (removed) CONFIG_CHARGER_MIN_BAT_PCT_FOR_POWER_ON_WITH_AC = 1 This allows us to show the low battery alert whenever we can because EC doesn't inhibit power-on even if it knows the host would immediately shut down. With CONFIG_BATTERY_EXPORT_DISPLAY_SOC, boards will start using the CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE = 2% as the low battery threshold (and the SoC will be agreed between the EC and Powerd). Boards with CONFIG_CHARGER_MIN_BAT_PCT_FOR_POWER_ON = 1 will keep the same threshold. This is for avoiding degrading the UX by increasing the power-on threshold (even though a question that 1% may not be enough for soft sync to finish consistently remains to be answered). Boards with CONFIG_CHARGER_MIN_BAT_PCT_FOR_POWER_ON > 2 will have a lower threshold but we think 2% is enough to finish the software sync. A lower threshold also improves the UX by showing the low battery alert in the situation where otherwise the system would leave the user uninformed by not responding to a power button press. BUG=b:191837893 BRANCH=None TEST=buildall Change-Id: If6ff733bc181f929561a3fffb8a84e760668ce37 Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2981468 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Diffstat (limited to 'board/storo/board.h')
-rw-r--r--board/storo/board.h3
1 files changed, 0 insertions, 3 deletions
diff --git a/board/storo/board.h b/board/storo/board.h
index 48d4882eb4..87525dd071 100644
--- a/board/storo/board.h
+++ b/board/storo/board.h
@@ -18,9 +18,6 @@
/* Battery */
#define CONFIG_BATTERY_FUEL_GAUGE
-#define CONFIG_BATTERY_EXPORT_DISPLAY_SOC
-#undef CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE
-#define CONFIG_BATT_HOST_SHUTDOWN_PERCENTAGE 3
/* BC 1.2 */
#define CONFIG_BC12_DETECT_PI3USB9201