diff options
author | Diana Z <dzigterman@chromium.org> | 2020-01-30 15:30:06 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-02-04 22:10:57 +0000 |
commit | d6db0a0c88b80b8505a3c139e06a63203433e8ea (patch) | |
tree | 24a3b7ab4ee8ef618328feb929c31bf26608108c /board/tglrvpu_ite | |
parent | ccc649887ba991c82a338359c0e415e7e2d0698e (diff) | |
download | chrome-ec-d6db0a0c88b80b8505a3c139e06a63203433e8ea.tar.gz |
Charger: Convert boards to use new driver structure
This commit removes the temporary common charger chip configuration and
instead puts the configuration in each board.
BRANCH=none
BUG=b:147672225
TEST=builds, runs on waddledoo and octopus
Change-Id: If81aef31e48c65999a87e202494f286716114bbb
Signed-off-by: Diana Z <dzigterman@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2031855
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
Diffstat (limited to 'board/tglrvpu_ite')
-rw-r--r-- | board/tglrvpu_ite/board.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/board/tglrvpu_ite/board.c b/board/tglrvpu_ite/board.c index 93a7d18984..c46772aaaa 100644 --- a/board/tglrvpu_ite/board.c +++ b/board/tglrvpu_ite/board.c @@ -6,6 +6,8 @@ /* Intel TGL-U-RVP-ITE board-specific configuration */ #include "button.h" +#include "charger.h" +#include "driver/charger/isl9241.h" #include "extpower.h" #include "i2c.h" #include "intc.h" @@ -106,6 +108,17 @@ const struct i2c_port_t i2c_ports[] = { BUILD_ASSERT(ARRAY_SIZE(i2c_ports) == I2C_CHAN_COUNT); const unsigned int i2c_ports_used = ARRAY_SIZE(i2c_ports); +/* Charger Chips */ +const struct charger_config_t chg_chips[] = { + { + .i2c_port = I2C_PORT_CHARGER, + .i2c_addr_flags = ISL9241_ADDR_FLAGS, + .drv = &isl9241_drv, + }, +}; + +const unsigned int chg_cnt = ARRAY_SIZE(chg_chips); + /* * Returns board information (board id[7:0] and Fab id[15:8]) on success * -1 on error. |