diff options
Diffstat (limited to 'include/usbc_ppc.h')
-rw-r--r-- | include/usbc_ppc.h | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/include/usbc_ppc.h b/include/usbc_ppc.h index eec8362959..54142b2921 100644 --- a/include/usbc_ppc.h +++ b/include/usbc_ppc.h @@ -49,6 +49,15 @@ struct ppc_drv { int (*vbus_source_enable)(int port, int enable); /** + * Inform the PPC of the polarity of the CC pins. + * + * @param port: The Type-C port number. + * @param polarity: 1: CC2 used for comms, 0: CC1 used for comms. + * @return EC_SUCCESS on success, error otherwise. + */ + int (*set_polarity)(int port, int polarity); + + /** * Set the Vbus source path current limit * * @param port: The Type-C port number. @@ -66,6 +75,14 @@ struct ppc_drv { */ int (*discharge_vbus)(int port, int enable); + /** + * Turn on/off the VCONN FET. + * + * @param port: The Type-C port number. + * @param enable: 1: enable VCONN FET 0: disable VCONN FET. + */ + int (*set_vconn)(int port, int enable); + #ifdef CONFIG_CMD_PPC_DUMP /** * Perform a register dump of the PPC. @@ -121,6 +138,15 @@ int ppc_is_vbus_present(int port); int ppc_is_sourcing_vbus(int port); /** + * Inform the PPC of the polarity of the CC pins. + * + * @param port: The Type-C port number. + * @param polarity: 1: CC2 used for comms, 0: CC1 used for comms. + * @return EC_SUCCESS on success, error otherwise. + */ +int ppc_set_polarity(int port, int polarity); + +/** * Set the Vbus source path current limit * * @param port: The Type-C port number. @@ -130,6 +156,14 @@ int ppc_is_sourcing_vbus(int port); int ppc_set_vbus_source_current_limit(int port, enum tcpc_rp_value rp); /** + * Turn on/off the VCONN FET. + * + * @param port: The Type-C port number. + * @param enable: 1: enable VCONN FET 0: disable VCONN FET. + */ +int ppc_set_vconn(int port, int enable); + +/** * Discharge PD VBUS on src/sink disconnect & power role swap * * @param port: The Type-C port number. |