diff options
author | Dawid Niedzwiecki <dn@semihalf.com> | 2021-01-25 15:33:22 +0100 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-01-28 17:50:21 +0000 |
commit | b07b50c8a279880e97b2da7d6680ff61b3f3eda9 (patch) | |
tree | 7c82061d0912cd4faff7f9aedd48932499238883 /zephyr/Kconfig.battery | |
parent | 2f40b71b625bcd826fd0cb4a005985abef0b8903 (diff) | |
download | chrome-ec-b07b50c8a279880e97b2da7d6680ff61b3f3eda9.tar.gz |
zephyr: Add missing battery config
There are 3 battery configs missing for Zephyr:
-CONFIG_PLATFORM_EC_BATTERY_CUT_OFF
-CONFIG_PLATFORM_EC_BATTERY_HW_PRESENT_CUSTOM
-CONFIG_PLATFORM_EC_BATTERY_REVIVE_DISCONNECT
Add them to the Kconfig.battery.
BUG=b:177604307
BRANCH=none
TEST=Build Zephyr with the configs enabled
Signed-off-by: Dawid Niedzwiecki <dn@semihalf.com>
Change-Id: I4e3c834470b9f4977b3f779b4246868feaea4bd7
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2645092
Reviewed-by: Keith Short <keithshort@chromium.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Commit-Queue: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'zephyr/Kconfig.battery')
-rw-r--r-- | zephyr/Kconfig.battery | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/zephyr/Kconfig.battery b/zephyr/Kconfig.battery index 74e1265aaf..995373f233 100644 --- a/zephyr/Kconfig.battery +++ b/zephyr/Kconfig.battery @@ -124,4 +124,29 @@ config PLATFORM_EC_CMD_CHGRAMP OC 1: s0 oc_det0 icl0 OC 2: s0 oc_det0 icl0 +config PLATFORM_EC_BATTERY_CUT_OFF + bool "Host/Console command: battery cut-off" + help + Enables support for disconnecting the battery using the "cutoff" + console command and the EC_CMD_BATTERY_CUT_OFF host command. + Once defined, a board specific board_cut_off_battery() function + has to be provided. + +config PLATFORM_EC_BATTERY_HW_PRESENT_CUSTOM + bool "Hardware check of battery presence" + help + Once defined, the charger will check a board specific function + battery_hw_present() for battery hw presence as an additional + condition to determine if power on is allowed for factory override, + where allowing booting of a bare board with no battery and no power + button press is required. + +config PLATFORM_EC_BATTERY_REVIVE_DISCONNECT + bool "Check battery disconnect state" + help + Check for battery in disconnect state (similar to cut-off state). + If this battery is found to be in disconnect state, take it out of + this state by force-applying a charge current. Once defined, + a battery_get_disconnect_state() function has to be provided. + endif # PLATFORM_EC_BATTERY |