diff options
-rw-r--r-- | board/meep/board.c | 17 | ||||
-rw-r--r-- | board/meep/board.h | 4 |
2 files changed, 21 insertions, 0 deletions
diff --git a/board/meep/board.c b/board/meep/board.c index a739ae7eaf..46d0234b37 100644 --- a/board/meep/board.c +++ b/board/meep/board.c @@ -9,6 +9,7 @@ #include "adc_chip.h" #include "battery.h" #include "button.h" +#include "cbi_ssfc.h" #include "charge_manager.h" #include "charge_state.h" #include "common.h" @@ -352,6 +353,22 @@ uint32_t board_override_feature_flags1(uint32_t flags1) return flags1; } +__override uint16_t board_get_ps8xxx_product_id(int port) +{ + /* Meep variant doesn't have ps8xxx product in the port 0 */ + if (port == 0) + return 0; + + switch (get_cbi_ssfc_tcpc_p1()) { + case TCPC_P1_PS8755: + return PS8755_PRODUCT_ID; + case TCPC_P1_DEFAULT: + case TCPC_P1_PS8751: + default: + return PS8751_PRODUCT_ID; + } +} + const struct ppc_config_t ppc_syv682x_port0 = { .i2c_port = I2C_PORT_TCPC0, .i2c_addr = SYV682X_ADDR0, diff --git a/board/meep/board.h b/board/meep/board.h index ce2eb3183a..95fd082eb2 100644 --- a/board/meep/board.h +++ b/board/meep/board.h @@ -56,6 +56,10 @@ /* Additional PPC second source */ #define CONFIG_USBC_PPC_SYV682X +/* Additional TCPC second source in Port 1 */ +#define CONFIG_USB_PD_TCPM_MULTI_PS8XXX +#define CONFIG_USB_PD_TCPM_PS8755 + #ifndef __ASSEMBLER__ #include "gpio_signal.h" |