summaryrefslogtreecommitdiff
path: root/board/brya
diff options
context:
space:
mode:
authorCaveh Jalali <caveh@chromium.org>2021-02-24 00:42:14 -0800
committerCommit Bot <commit-bot@chromium.org>2021-02-27 04:04:45 +0000
commit6ab80fd4094be30ef9e454f3f531826c4b1b7d2b (patch)
tree3c5c3fcdbb2e9f55b2f9c3d989f8bb46709d8de1 /board/brya
parent120d54402d03944f32230ccfbb943a6707a16676 (diff)
downloadchrome-ec-6ab80fd4094be30ef9e454f3f531826c4b1b7d2b.tar.gz
brya: Enable USB-A port power control
This enables power control (i.e. "charging") of the USB-A port located on the USB daughtercard. This is required to power devices connected to the port. BRANCH=none BUG=b:173575131 TEST=USB LED flash light powers on Signed-off-by: Caveh Jalali <caveh@chromium.org> Change-Id: Id8bcf07a6632b909e7c28b5800d035f05fea0ef6 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2717806 Reviewed-by: Keith Short <keithshort@chromium.org>
Diffstat (limited to 'board/brya')
-rw-r--r--board/brya/board.c10
-rw-r--r--board/brya/board.h4
2 files changed, 14 insertions, 0 deletions
diff --git a/board/brya/board.c b/board/brya/board.c
index b27eb0ce8c..f1f905fe39 100644
--- a/board/brya/board.c
+++ b/board/brya/board.c
@@ -11,6 +11,16 @@
#include "gpio_list.h" /* Must come after other header files. */
+/******************************************************************************/
+/* USB-A charging control */
+
+const int usb_port_enable[USB_PORT_COUNT] = {
+ GPIO_EN_PP5000_USBA_R,
+};
+BUILD_ASSERT(ARRAY_SIZE(usb_port_enable) == USB_PORT_COUNT);
+
+/******************************************************************************/
+
/*
* remove when we enable CONFIG_POWER_BUTTON
*/
diff --git a/board/brya/board.h b/board/brya/board.h
index 26cd4de40b..8a31003481 100644
--- a/board/brya/board.h
+++ b/board/brya/board.h
@@ -23,6 +23,10 @@
#undef CONFIG_SPI_FLASH
#undef CONFIG_SWITCH
+/* USB Type A Features */
+#define USB_PORT_COUNT 1
+#define CONFIG_USB_PORT_POWER_DUMB
+
/* USB Type C and USB PD defines */
#define CONFIG_IO_EXPANDER_PORT_COUNT 2