summaryrefslogtreecommitdiff
path: root/board/kohaku/board.c
diff options
context:
space:
mode:
authorScott Collyer <scollyer@google.com>2019-04-18 15:19:28 -0700
committerchrome-bot <chrome-bot@chromium.org>2019-04-20 03:58:33 -0700
commitafbb1b511cdf5ab36ce2f6969ac701322fe91517 (patch)
tree6c3c7cc11abf6606634a09cf80ce310cc8c25891 /board/kohaku/board.c
parente25a0bc9539161c0222166b2d63057a4ecca4f7a (diff)
downloadchrome-ec-afbb1b511cdf5ab36ce2f6969ac701322fe91517.tar.gz
hatch/kohaku: Account for different bc1.2 chips
This CL moves bc1.2 configuration from baseboard.c/.h to the board.c/.h files for hatch and kohaku. BUG=b:130197995 BRANCH=none TEST=make -j BOARD=hatch and make -j BOARD=kohaku both are successful Change-Id: I2aa44d37a7a1d23196a766c95c59737838e9e09f Signed-off-by: Scott Collyer <scollyer@google.com> Reviewed-on: https://chromium-review.googlesource.com/1574788 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Reviewed-by: Furquan Shaikh <furquan@chromium.org>
Diffstat (limited to 'board/kohaku/board.c')
-rw-r--r--board/kohaku/board.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/board/kohaku/board.c b/board/kohaku/board.c
index 6511ee31f6..69fce0a932 100644
--- a/board/kohaku/board.c
+++ b/board/kohaku/board.c
@@ -14,6 +14,7 @@
#include "driver/accelgyro_bmi160.h"
#include "driver/als_opt3001.h"
#include "driver/ppc/sn5s330.h"
+#include "driver/bc12/max14637.h"
#include "driver/tcpm/ps8xxx.h"
#include "driver/tcpm/tcpci.h"
#include "ec_commands.h"
@@ -135,6 +136,20 @@ struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_COUNT] = {
}
};
+/* BC 1.2 chip Configuration */
+const struct max14637_config_t max14637_config[CONFIG_USB_PD_PORT_COUNT] = {
+ {
+ .chip_enable_pin = GPIO_USB_C0_BC12_VBUS_ON,
+ .chg_det_pin = GPIO_USB_C0_BC12_CHG_DET_L,
+ .flags = MAX14637_FLAGS_CHG_DET_ACTIVE_LOW,
+ },
+ {
+ .chip_enable_pin = GPIO_USB_C1_BC12_VBUS_ON,
+ .chg_det_pin = GPIO_USB_C1_BC12_CHG_DET_L,
+ .flags = MAX14637_FLAGS_CHG_DET_ACTIVE_LOW,
+ },
+};
+
/******************************************************************************/
/* Sensors */
/* Base Sensor mutex */