summaryrefslogtreecommitdiff
path: root/board/reef_it8320/board.c
diff options
context:
space:
mode:
authorDaisuke Nojiri <dnojiri@chromium.org>2019-05-31 16:45:32 -0700
committerchrome-bot <chrome-bot@chromium.org>2019-06-10 21:20:17 -0700
commit3a668749460466ff002b5dd2cbf00529f97e5974 (patch)
tree4f62d4856086362ebc646215c0d4ac31cdaf8b08 /board/reef_it8320/board.c
parentc89e3557f808c504d8feece4d28a96450089b05f (diff)
downloadchrome-ec-3a668749460466ff002b5dd2cbf00529f97e5974.tar.gz
TCPC: Make tcpc_config handle other bus types
Currently, tcpc_config assumes TCPCs are on I2C bus. ITE's EC has an embedded TCPC. This patch adds bus_type field to struct tcpc_config_t so that a TCPC location on other type of bus can be specified. Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org> BUG=none BRANCH=none TEST=buildall Change-Id: Ieac733011700b351e6323f46070dcf46d9e1154b Reviewed-on: https://chromium-review.googlesource.com/1640305 Commit-Ready: Daisuke Nojiri <dnojiri@chromium.org> Tested-by: Daisuke Nojiri <dnojiri@chromium.org> Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org> Reviewed-by: Jett Rink <jettrink@chromium.org>
Diffstat (limited to 'board/reef_it8320/board.c')
-rw-r--r--board/reef_it8320/board.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/board/reef_it8320/board.c b/board/reef_it8320/board.c
index 03ce723338..47c63c0599 100644
--- a/board/reef_it8320/board.c
+++ b/board/reef_it8320/board.c
@@ -94,8 +94,14 @@ const struct i2c_port_t i2c_ports[] = {
const unsigned int i2c_ports_used = ARRAY_SIZE(i2c_ports);
const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_COUNT] = {
- {-1, -1, &it83xx_tcpm_drv, 0},
- {-1, -1, &it83xx_tcpm_drv, 0},
+ {
+ .bus_type = EC_BUS_TYPE_EMBEDDED,
+ .drv = &it83xx_tcpm_drv
+ },
+ {
+ .bus_type = EC_BUS_TYPE_EMBEDDED,
+ .drv = &it83xx_tcpm_drv
+ },
};
void board_pd_vconn_ctrl(int port, int cc_pin, int enabled)