summaryrefslogtreecommitdiff
path: root/board/reef_it8320/board.h
diff options
context:
space:
mode:
authorNicolas Boichat <drinkcat@chromium.org>2018-01-03 08:55:06 +0800
committerchrome-bot <chrome-bot@chromium.org>2018-01-10 06:02:13 -0800
commit1caa2788c5198f3a89e022a559191b27b93adada (patch)
treea3e2880eb8f394ca776c4813150bfb95b1068629 /board/reef_it8320/board.h
parentb167a193e66e3c05ad61d997994072e36cb73773 (diff)
downloadchrome-ec-1caa2788c5198f3a89e022a559191b27b93adada.tar.gz
charger/isl923x: Implement charger_get_system_power from PSYS
On ISL923x, PSYS output is always enabled when the AP is on (provided CONFIG_CHARGER_PSYS is enabled). We add support for charger_get_system_power function, reading PSYS value, when CONFIG_CHARGER_PSYS_READ is defined. This will be used by the charging algorithm on lux. We also rename CONFIG_CMD_CHARGER_PSYS to CONFIG_CHARGER_PSYS_READ as CONFIG_CHARGER_PSYS_READ provides both "psys" console command and the new function. We also cleanup unneeded undefs in board files. Note that this does not implement the function on bd9995x, but this could be done without too much effort. BRANCH=none BUG=b:71520677 TEST=On lux, without AC connected, check that "psys" output roughly matches the output current from the battery. Signed-off-by: Nicolas Boichat <drinkcat@chromium.org> Change-Id: Ie1ce8e0ac103daacc5a08b8ccae604d1d83551b8 Reviewed-on: https://chromium-review.googlesource.com/848487 Commit-Ready: Nicolas Boichat <drinkcat@chromium.org> Tested-by: Nicolas Boichat <drinkcat@chromium.org> Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'board/reef_it8320/board.h')
-rw-r--r--board/reef_it8320/board.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/board/reef_it8320/board.h b/board/reef_it8320/board.h
index a7983e03b2..099cfe273d 100644
--- a/board/reef_it8320/board.h
+++ b/board/reef_it8320/board.h
@@ -24,7 +24,7 @@
#define BD9995X_IOUT_GAIN_SELECT \
BD9995X_CMD_PMON_IOUT_CTRL_SET_IOUT_GAIN_SET_20V
-#define CONFIG_CMD_CHARGER_PSYS
+#define CONFIG_CHARGER_PSYS_READ
#define BD9995X_PSYS_GAIN_SELECT \
BD9995X_CMD_PMON_IOUT_CTRL_SET_PMON_GAIN_SET_02UAW