drm/bridge: Add Lontium LT8711UXD DP-to-HDMI transparent bridge
Subsystems (5)
cover drm/bridge: Add Lontium LT8711UXD DP-to-HDMI transparent bridge
The Lontium LT8711UXD supports two modes of operation: autonomous mode, where it configures itself via strapping resistors, and I2C-controlled mode. Review of the earlier Orange Pi 5 Pro series raised the question of how a future board requiring I2C control should be handled, a second compatible with a driver or we make both work with a single compatible
This patch set covers autonomous mode only. On the Orange Pi 5 Pro, resistors R9, R17, and R27 are unpopulated, which straps MODE_SEL low leaving the device invisible on the I2C bus; I2C control is not enabled on this board.
The earlier review thread is at:
https://lore.kernel.org/linux-devicetree/[email protected]/
One non-obvious detail in the DTS patch: vcc3v3_dp carries regulator-always-on because simple-bridge only fires pre_enable once a modeset starts, but no modeset will start until the connector reports connected, and the connector won't report connected until HPD asserts, and HPD won't assert until the bridge is powered. Holding the enable line high from boot breaks this deadlock.
Tested on Orange Pi 5 Pro with Linux 7.0: HPD asserts, EDID reads, link trains, and scanout reaches the display.
Please take a look.
Thank you,
Dennis Gilmore
Dennis Gilmore (3):
dt-bindings: display: bridge: simple: document the Lontium LT8711UXD
DP-to-HDMI bridge
drm/bridge: simple: Add the Lontium LT8711UXD DP-to-HDMI bridge
arm64: dts: rockchip: orangepi-5-pro: Add LT8711UXD DP-to-HDMI bridge
.../display/bridge/simple-bridge.yaml | 1 + .../dts/rockchip/rk3588s-orangepi-5-pro.dts | 88 ++++++++++++++++++- drivers/gpu/drm/bridge/simple-bridge.c | 5 ++ 3 files changed, 91 insertions(+), 3 deletions(-)
Signature · 1 line
2.54.0
PATCH 1/3 dt-bindings: display: bridge: simple: document the Lontium LT8711UXD DP-to-HDMI bridge
The Lontium LT8711UXD is a high performance two lane Type-C/DP1.4 to HDMI2.0 converter, designed to connect a USB Type-C source or a DP1.4 source to an HDMI2.0 sink. The device can be running uncontrolled or it can be attached over I2C, the bindings describe the uncontrolled mode.
--- .../devicetree/bindings/display/bridge/simple-bridge.yaml | 1 + 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml +1 -0
@@ -30,6 +30,7 @@ properties: - algoltek,ag6311 - asl-tek,cs5263 - dumb-vga-dac + - lontium,lt8711uxd - parade,ps185hdm - radxa,ra620 - realtek,rtd2171
Signature · 1 line
2.54.0
PATCH 2/3 drm/bridge: simple: Add the Lontium LT8711UXD DP-to-HDMI bridge
In reply to Dennis GilmoreThe Lontium LT8711UXD is a high performance two lane Type-C/DP1.4 to HDMI2.0 converter, designed to connect a USB Type-C source or a DP1.4 source to an HDMI2.0 sink. The device can be run uncontrolled or it can be attached over I2C, this supports the uncontrolled mode.
--- drivers/gpu/drm/bridge/simple-bridge.c | 5 +++++ 1 file changed, 5 insertions(+)
drivers/gpu/drm/bridge/simple-bridge.c +5 -0
@@ -270,6 +270,11 @@ static const struct of_device_id simple_bridge_match[] = { .data = &(const struct simple_bridge_info) { .connector_type = DRM_MODE_CONNECTOR_HDMIA, }, + }, { + .compatible = "lontium,lt8711uxd", + .data = &(const struct simple_bridge_info) { + .connector_type = DRM_MODE_CONNECTOR_HDMIA, + }, }, { .compatible = "parade,ps185hdm", .data = &(const struct simple_bridge_info) {
Signature · 1 line
2.54.0
PATCH 3/3 arm64: dts: rockchip: orangepi-5-pro: Add LT8711UXD DP-to-HDMI bridge
In reply to Dennis GilmoreWire up the second HDMI port on the Orange Pi 5 Pro. It uses a Lontium LT8711UXD high performance two lane Type-C/DP1.4 to HDMI2.0 converter, designed to connect a USB Type-C source or a DP1.4 source to an HDMI2.0 sink. The bridge can be controlled via i2c or run as an autonomous device.
The Orange Pi 5 Pro has i2c wired up to i2c6, however there are 10k resistors left off of R9 and R17 to enable MODE_SEL, and R27 for I2C_ADDR resulting in MODE_SEL going to GND and the bridge let in autonomous mode. As shipped I verified that the bridge does not show up on the i2c bus.
--- .../dts/rockchip/rk3588s-orangepi-5-pro.dts | 88 ++++++++++++++++++- 1 file changed, 85 insertions(+), 3 deletions(-)
arch/arm64/boot/dts/rockchip/rk3588s-orangepi-5-pro.dts +85 -3
@@ -14,6 +14,44 @@ aliases { mmc2 = &sdio; }; + hdmi1-con { + compatible = "hdmi-connector"; + label = "HDMI1 OUT"; + type = "a"; + + port { + hdmi1_con_in: endpoint { + remote-endpoint = <<8711uxd_out>; + }; + }; + }; + + hdmi-bridge { + compatible = "lontium,lt8711uxd"; + vdd-supply = <&vcc3v3_dp>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + lt8711uxd_in: endpoint { + remote-endpoint = <&dp0_out_con>; + }; + }; + + port@1 { + reg = <1>; + + lt8711uxd_out: endpoint { + remote-endpoint = <&hdmi1_con_in>; + }; + }; + }; + }; + analog-sound { compatible = "simple-audio-card"; pinctrl-names = "default";
@@ -72,6 +110,19 @@ fan: pwm-fan { pwms = <&pwm2 0 20000000 0>; }; + vcc3v3_dp: regulator-vcc3v3-dp { + compatible = "regulator-fixed"; + enable-active-high; + gpios = <&gpio3 RK_PC2 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&dp_bridge_en>; + regulator-max-microvolt = <3300000>; + regulator-min-microvolt = <3300000>; + regulator-name = "vcc3v3_dp"; + regulator-always-on; + vin-supply = <&vcc_3v3_s3>; + }; + vcc3v3_eth: regulator-vcc3v3-eth { compatible = "regulator-fixed"; enable-active-high;
@@ -116,6 +167,24 @@ typea_con: usb-a-connector { }; }; +&dp0 { + pinctrl-names = "default"; + pinctrl-0 = <&dp0m0_pins>; + status = "okay"; +}; + +&dp0_in { + dp0_in_vp1: endpoint { + remote-endpoint = <&vp1_out_dp0>; + }; +}; + +&dp0_out { + dp0_out_con: endpoint { + remote-endpoint = <<8711uxd_in>; + }; +}; + &i2c1 { pinctrl-names = "default"; pinctrl-0 = <&i2c1m4_xfer>;
@@ -217,6 +286,12 @@ bt_wake_host_irq: bt-wake-host-irq { }; }; + dp { + dp_bridge_en: dp-bridge-en { + rockchip,pins = <3 RK_PC2 RK_FUNC_GPIO &pcfg_pull_down>; + }; + }; + ethernet { ethernet_en: ethernet-en { rockchip,pins = <3 RK_PB7 RK_FUNC_GPIO &pcfg_pull_down>;
@@ -350,9 +425,16 @@ &usb_host0_xhci { &usbdp_phy0 { /* - * The USB3 Type-A host connector is wired to PHY lanes 2/3. Lanes 0/1 - * are connected to the LT8711UXD DP-to-HDMI bridge on the board. - * dp-lane-mux routes USB3 SuperSpeed to the correct lanes. + * USBDP PHY0 is wired to a USB3 Type-A host connector via lanes 2/3. + * Additionally lanes 0/1 and the aux channel are wired to the + * Lontium LT8711UXD DP-to-HDMI bridge feeding the HDMI1 connector. */ rockchip,dp-lane-mux = <0 1>; }; + +&vp1 { + vp1_out_dp0: endpoint@a { + reg = <ROCKCHIP_VOP2_EP_DP0>; + remote-endpoint = <&dp0_in_vp1>; + }; +};
Signature · 1 line
2.54.0