diff options
author | Scott Collyer <scollyer@google.com> | 2021-11-23 15:04:49 -0800 |
---|---|---|
committer | Scott Collyer <scollyer@google.com> | 2021-11-23 15:04:49 -0800 |
commit | 817cf2223b0b33c91ca6e369b644cbc4d6c361e3 (patch) | |
tree | f698bbab73d87af25f9fdc2d49f50a0c25111a79 /board/goroh/usbc_confg.c | |
parent | 6da8436a8ce04a7f88f80049a10638e1b8f6439d (diff) | |
parent | 0349a5b6d95308141754523708a2d11d8bacce4c (diff) | |
download | chrome-ec-817cf2223b0b33c91ca6e369b644cbc4d6c361e3.tar.gz |
Merge remote-tracking branch 'cros/main' into firmware-gwc-fsi
Change-Id: Id9b5b5cb1db7428cd9f12452d73842d8c1f2705a
Diffstat (limited to 'board/goroh/usbc_confg.c')
-rw-r--r-- | board/goroh/usbc_confg.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/board/goroh/usbc_confg.c b/board/goroh/usbc_confg.c new file mode 100644 index 0000000000..57a52da986 --- /dev/null +++ b/board/goroh/usbc_confg.c @@ -0,0 +1,33 @@ +/* Copyright 2021 The Chromium OS Authors. All rights reserved. + * Use of this source code is governed by a BSD-style license that can be + * found in the LICENSE file. + */ + +#include <stdint.h> +#include <stdbool.h> + +#include "common.h" +#include "compile_time_macros.h" +#include "console.h" +#include "driver/bc12/pi3usb9201_public.h" +#include "driver/ppc/nx20p348x.h" +#include "driver/ppc/syv682x_public.h" +#include "driver/retimer/bb_retimer_public.h" +#include "driver/tcpm/nct38xx.h" +#include "driver/tcpm/ps8xxx_public.h" +#include "driver/tcpm/tcpci.h" +#include "ec_commands.h" +#include "fw_config.h" +#include "gpio.h" + +static void board_tcpc_init(void) +{ + /* Don't reset TCPCs after initial reset */ + if (!system_jumped_late()) + board_reset_pd_mcu(); + + /* Enable PPC interrupts. */ + gpio_enable_interrupt(GPIO_USB_C0_FAULT_ODL); + gpio_enable_interrupt(GPIO_USB_C1_FAULT_ODL); +} +DECLARE_HOOK(HOOK_INIT, board_tcpc_init, HOOK_PRIO_INIT_CHIPSET); |