From abe6e3055dc059aae19984c8cfc7bc4a484b05b2 Mon Sep 17 00:00:00 2001 From: Denis Brockus Date: Thu, 15 Jul 2021 14:50:48 -0600 Subject: asurada: add baseboard_init into common zephyr/cros-ec This was added to baseboard.c but does not seem to be there anymore. The GPIOs are needed to enable USB-A after XHCI is completely initialized. BUG=b:187149602 BRANCH=none TEST=verify boot GPIOs enable USB-A VBUS after XHCI_INIT_DONE Signed-off-by: Denis Brockus Change-Id: Ieb5fb2e77722c308b3675cb54884115e4f88912a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3033323 Tested-by: Denis Brockus Auto-Submit: Denis Brockus Reviewed-by: Keith Short Commit-Queue: Keith Short --- baseboard/asurada/usbc_config.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'baseboard') diff --git a/baseboard/asurada/usbc_config.c b/baseboard/asurada/usbc_config.c index b6332c3eab..c770efdb70 100644 --- a/baseboard/asurada/usbc_config.c +++ b/baseboard/asurada/usbc_config.c @@ -49,6 +49,15 @@ const struct charger_config_t chg_chips[] = { }, }; +/* Baseboard */ + +static void baseboard_init(void) +{ + gpio_enable_interrupt(GPIO_USB_C0_BC12_INT_ODL); + gpio_enable_interrupt(GPIO_AP_XHCI_INIT_DONE); +} +DECLARE_HOOK(HOOK_INIT, baseboard_init, HOOK_PRIO_DEFAULT-1); + /* Sub-board */ enum board_sub_board board_get_sub_board(void) -- cgit v1.2.1