diff options
author | xiong.huang <xiong.huang@bitland.corp-partner.google.com> | 2020-07-07 17:26:13 +0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-07-10 05:38:52 +0000 |
commit | 776faf4e76a7dbc3b609eed86de2837af220d408 (patch) | |
tree | 84a1a4b17fccc60cf256b9ac56d99b9c57419067 /board/boten | |
parent | 1c48fb8a646c53a71db970fc17b397cbe8f99e62 (diff) | |
download | chrome-ec-776faf4e76a7dbc3b609eed86de2837af220d408.tar.gz |
boten: enable DB HDMI
Signal EC_AP_USB_C1_HDMI_HPD(EC->AP) status is opposite to signal
HDMI_HPD_SUB_ODL(HDMI->EC). Keep signal HDMI_EN_SUB_ODL low level.
BUG=b:160668999
BRANCH=none
TEST=make buildall -j
Signed-off-by: xiong.huang <xiong.huang@bitland.corp-partner.google.com>
Change-Id: I3d3d88e7be5543d49508bb7023c39764ab84abdf
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2284511
Reviewed-by: Diana Z <dzigterman@chromium.org>
Diffstat (limited to 'board/boten')
-rw-r--r-- | board/boten/board.c | 8 | ||||
-rw-r--r-- | board/boten/gpio.inc | 6 |
2 files changed, 11 insertions, 3 deletions
diff --git a/board/boten/board.c b/board/boten/board.c index 29b09ef0d0..160beff602 100644 --- a/board/boten/board.c +++ b/board/boten/board.c @@ -40,6 +40,11 @@ #define CPRINTUSB(format, args...) cprints(CC_USBCHARGE, format, ## args) +static void hdmi_hpd_interrupt(enum gpio_signal s) +{ + gpio_set_level(GPIO_USB_C1_DP_HPD, !gpio_get_level(s)); +} + static void usb_c0_interrupt(enum gpio_signal s) { /* @@ -107,6 +112,9 @@ void board_init(void) gpio_enable_interrupt(GPIO_USB_C0_CCSBU_OVP_ODL); /* Enable gpio interrupt for base accelgyro sensor */ gpio_enable_interrupt(GPIO_BASE_SIXAXIS_INT_L); + gpio_enable_interrupt(GPIO_HDMI_HPD_SUB_ODL); + + gpio_set_level(GPIO_HDMI_EN_SUB_ODL, 0); } DECLARE_HOOK(HOOK_INIT, board_init, HOOK_PRIO_DEFAULT); diff --git a/board/boten/gpio.inc b/board/boten/gpio.inc index 512ec0b992..8ce426b2ab 100644 --- a/board/boten/gpio.inc +++ b/board/boten/gpio.inc @@ -39,6 +39,7 @@ GPIO_INT(VOLDN_BTN_ODL, PIN(I, 6), GPIO_INT_BOTH | GPIO_PULL_UP, button_interru GPIO_INT(VOLUP_BTN_ODL, PIN(I, 7), GPIO_INT_BOTH | GPIO_PULL_UP, button_interrupt) GPIO_INT(BASE_SIXAXIS_INT_L, PIN(J, 0), GPIO_INT_FALLING | GPIO_SEL_1P8V, lsm6dsm_interrupt) GPIO_INT(EC_WP_OD, PIN(A, 6), GPIO_INT_BOTH, switch_interrupt) +GPIO_INT(HDMI_HPD_SUB_ODL, PIN(E, 7), GPIO_INT_BOTH, hdmi_hpd_interrupt) /* Power sequence GPIOs */ GPIO(EC_AP_RTCRST, PIN(K, 2), GPIO_OUT_LOW) @@ -79,9 +80,8 @@ GPIO(EN_USB_A0_VBUS, PIN(L, 6), GPIO_OUT_HIGH) GPIO(EN_USB_A1_VBUS, PIN(E, 6), GPIO_OUT_LOW) GPIO(EC_AP_USB_C0_HPD, PIN(L, 4), GPIO_OUT_LOW) GPIO(EC_AP_USB_C1_HDMI_HPD, PIN(K, 7), GPIO_OUT_LOW) -GPIO(HDMI_SEL_L, PIN(C, 6), GPIO_OUT_HIGH) -GPIO(HDMI_EN_SUB_ODL, PIN(E, 0), GPIO_OUT_LOW) -GPIO(HDMI_HPD_SUB_ODL, PIN(E, 7), GPIO_INPUT) +GPIO(HDMI_SEL_L, PIN(C, 6), GPIO_OUT_LOW) +GPIO(HDMI_EN_SUB_ODL, PIN(E, 0), GPIO_OUT_HIGH) /* MKBP event synchronization */ GPIO(EC_AP_MKBP_INT_L, PIN(L, 5), GPIO_ODR_HIGH) |