diff options
-rw-r--r-- | baseboard/octopus/variant_usbc_ec_tcpcs.c | 17 | ||||
-rw-r--r-- | board/bip/gpio.inc | 2 |
2 files changed, 13 insertions, 6 deletions
diff --git a/baseboard/octopus/variant_usbc_ec_tcpcs.c b/baseboard/octopus/variant_usbc_ec_tcpcs.c index cb137ee06f..35365e232b 100644 --- a/baseboard/octopus/variant_usbc_ec_tcpcs.c +++ b/baseboard/octopus/variant_usbc_ec_tcpcs.c @@ -118,17 +118,24 @@ uint16_t tcpc_get_alert_status(void) } /** - * Reset all system PD/TCPC MCUs -- currently only called from - * handle_pending_reboot() in common/power.c just before hard - * resetting the system. This logic is likely not needed as the - * PP3300_A rail should be dropped on EC reset. + * Reset all system PD/TCPC MCUs -- currently called from both + * handle_pending_reboot() in common/system.c and baseboard_tcpc_init() in the + * octopus/baseboard.c */ void board_reset_pd_mcu(void) { /* * C0 & C1: The internal TCPC on ITE EC does not have a reset signal, - * but it will get reset when the EC gets reset. + * but it will get reset when the EC gets reset. We will, however, + * reset the USB muxes here. */ + gpio_set_level(GPIO_USB_C0_PD_RST_ODL, 0); + gpio_set_level(GPIO_USB_C1_PD_RST_ODL, 0); + + msleep(PS8XXX_RESET_DELAY_MS); + + gpio_set_level(GPIO_USB_C0_PD_RST_ODL, 1); + gpio_set_level(GPIO_USB_C1_PD_RST_ODL, 1); } void board_pd_vconn_ctrl(int port, int cc_pin, int enabled) diff --git a/board/bip/gpio.inc b/board/bip/gpio.inc index eca5c54bce..1e90024762 100644 --- a/board/bip/gpio.inc +++ b/board/bip/gpio.inc @@ -103,6 +103,7 @@ GPIO(USB_C0_BC12_CHG_DET_L, PIN(A, 0), GPIO_INPUT) /* C0 BC1.2 Detect */ GPIO(USB_C1_BC12_CHG_DET_L, PIN(A, 1), GPIO_INPUT) /* C1 BC1.2 Detect */ GPIO(USB_C0_BC12_VBUS_ON, PIN(J, 4), GPIO_OUT_LOW) /* C0 BC1.2 Power */ GPIO(USB_C1_BC12_VBUS_ON, PIN(J, 5), GPIO_OUT_LOW) /* C1 BC1.2 Power */ +GPIO(USB_C0_PD_RST_ODL, PIN(L, 6), GPIO_ODR_HIGH) /* NC, defined for shared reset code with ampton */ GPIO(USB_C1_PD_RST_ODL, PIN(L, 7), GPIO_ODR_HIGH) /* C1 PD Reset */ /* * Configure USB2_OTG_ID as ODR so that the EC never drives it high thus @@ -123,7 +124,6 @@ GPIO(GPIOG1_NC, PIN(G, 1), GPIO_INPUT | GPIO_PULL_DOWN) GPIO(GPIOH0_NC, PIN(H, 0), GPIO_INPUT | GPIO_PULL_DOWN) GPIO(GPIOL2_NC, PIN(L, 2), GPIO_INPUT | GPIO_PULL_DOWN) GPIO(GPIOL3_NC, PIN(L, 3), GPIO_INPUT | GPIO_PULL_DOWN) -GPIO(GPIOL6_NC, PIN(L, 6), GPIO_INPUT | GPIO_PULL_DOWN) GPIO(GPIOM6_NC, PIN(M, 6), GPIO_INPUT | GPIO_PULL_DOWN) /* Misc. */ |