summaryrefslogtreecommitdiff
path: root/driver/tcpm/it83xx_pd.h
diff options
context:
space:
mode:
Diffstat (limited to 'driver/tcpm/it83xx_pd.h')
-rw-r--r--driver/tcpm/it83xx_pd.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/driver/tcpm/it83xx_pd.h b/driver/tcpm/it83xx_pd.h
index c3efb7e150..ff7c231f23 100644
--- a/driver/tcpm/it83xx_pd.h
+++ b/driver/tcpm/it83xx_pd.h
@@ -379,6 +379,26 @@
IS_MASK_SET(IT83XX_USBPD_IFS(port), USBPD_REG_FAST_SWAP_DETECT_STAT)
#endif
+#if defined(CONFIG_USB_PD_TCPM_ITE_ON_CHIP) && defined(CONFIG_ZEPHYR)
+/* Use the Zephyr names here. When upstreaming we can update this */
+#include <dt-bindings/interrupt-controller/ite-intc.h>
+
+#define IT83XX_GPIO_GPCRF4 GPCRF4
+#define IT83XX_GPIO_GPCRF5 GPCRF5
+#define IT83XX_GPIO_GPCRH1 GPCRH1
+#define IT83XX_GPIO_GPCRH2 GPCRH2
+#define IT83XX_GPIO_GPCRP0 IT8XXX2_GPIO_GPCRP0
+#define IT83XX_GPIO_GPCRP1 IT8XXX2_GPIO_GPCRP1
+#define IT83XX_IRQ_USBPD0 IT8XXX2_IRQ_USBPD0
+#define IT83XX_IRQ_USBPD1 IT8XXX2_IRQ_USBPD1
+#define IT83XX_IRQ_USBPD2 IT8XXX2_IRQ_USBPD2
+#define USB_VID_ITE 0x048d
+
+/* ITE chip supports PD features */
+#define IT83XX_INTC_FAST_SWAP_SUPPORT
+#define IT83XX_INTC_PLUG_IN_OUT_SUPPORT
+#endif
+
enum usbpd_port {
USBPD_PORT_A,
USBPD_PORT_B,