summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEdward Hill <ecgh@chromium.org>2020-07-17 22:33:03 -0600
committerCommit Bot <commit-bot@chromium.org>2020-07-18 22:08:21 +0000
commit344c815877363277c71c7524355b474ae5049571 (patch)
treec71c883bf7745cb7e8827aae8f0cda86ffe8083a
parent1cdb7ae80f44b856a1f10c2430f9925bfb381555 (diff)
downloadchrome-ec-stabilize-13360.B-master.tar.gz
morphius: Allow MST hub to control HPD for OPT3 DBstabilize-13360.B-master
Use an UNIMPLEMENTED GPIO for PORT_TO_HPD so that EC does not drive HPD for OPT3 DB. BUG=b:152512560 BRANCH=none TEST=HDMI works on OPT3 DB Signed-off-by: Edward Hill <ecgh@chromium.org> Change-Id: I518899d8715e187d02ef5c90fdbe1aed126e00d5 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2305481 Reviewed-by: Denis Brockus <dbrockus@chromium.org>
-rw-r--r--board/morphius/board.h18
-rw-r--r--board/morphius/gpio.inc4
2 files changed, 10 insertions, 12 deletions
diff --git a/board/morphius/board.h b/board/morphius/board.h
index a517e061b7..7b87a3a26f 100644
--- a/board/morphius/board.h
+++ b/board/morphius/board.h
@@ -198,19 +198,15 @@ static inline bool ec_config_has_mst_hub_rtd2141b(void)
HAS_MST_HUB_RTD2141B);
}
-#define HAS_HDMI_CONN_HPD \
- (BIT(MORPHIUS_DB_T_OPT1_USBC_HDMI))
-
-static inline bool ec_config_has_hdmi_conn_hpd(void)
-{
- return !!(BIT(ec_config_get_usb_db()) &
- HAS_HDMI_CONN_HPD);
-}
-
+/*
+ * USB-C0 always uses USB_C0_HPD (= DP3_HPD).
+ * USB-C1 OPT1 DB uses DP2_HPD.
+ * USB-C1 OPT3 DB uses DP1_HPD via RTD2141B MST hub, EC does not drive HPD.
+ */
#define PORT_TO_HPD(port) ((port == 0) \
? GPIO_USB_C0_HPD \
- : (ec_config_has_usbc1_retimer_ps8802()) \
- ? GPIO_DP1_HPD \
+ : (ec_config_has_mst_hub_rtd2141b()) \
+ ? GPIO_NO_HPD \
: GPIO_DP2_HPD)
extern const struct usb_mux usbc0_pi3dpx1207_usb_retimer;
diff --git a/board/morphius/gpio.inc b/board/morphius/gpio.inc
index ac7b82d168..90183b4555 100644
--- a/board/morphius/gpio.inc
+++ b/board/morphius/gpio.inc
@@ -48,12 +48,14 @@ GPIO(USB_C0_TCPC_RST_L, PIN(E, 1), GPIO_OUT_HIGH) /* C0 TCPC Reset */
GPIO(USB_C1_TCPC_RST_L, PIN(F, 0), GPIO_OUT_HIGH) /* C1 TCPC Reset */
GPIO(USB_C0_HPD, PIN(F, 5), GPIO_OUT_LOW) /* C0 DP Hotplug Detect */
GPIO(USB_C0_IN_HPD, PIN(7, 3), GPIO_OUT_LOW) /* C0 IN Hotplug Detect */
-GPIO(DP1_HPD, PIN(F, 4), GPIO_OUT_LOW) /* C1 DP Hotplug Detect */
+GPIO(EC_DP1_HPD, PIN(F, 4), GPIO_OUT_LOW) /* C1 DP Hotplug Detect */
GPIO(DP2_HPD, PIN(C, 1), GPIO_OUT_LOW) /* C1 DP Hotplug Detect */
+GPIO(DP1_HPD_EC_IN, PIN(7, 5), GPIO_INPUT) /* C1 IN Hotplug Detect */
GPIO(EC_PS2_RESET_V0, PIN(3, 2), GPIO_OUT_LOW) /* Trackpoint reset pin V0*/
GPIO(EC_PS2_RESET_V1, PIN(4, 5), GPIO_OUT_LOW) /* Trackpoint reset pin V1 */
GPIO(EC_H1_PACKET_MODE, PIN(8, 6), GPIO_OUT_LOW) /* H1 Packet Mode */
+UNIMPLEMENTED(NO_HPD)
UNIMPLEMENTED(PCH_SMI_L)