* [PATCH v2 0/3] Add VGA support for Apalis iMX6
@ 2026-10-19 10:17 Leonardo Costa
2026-10-19 10:17 ` [PATCH v2 1/3] dt-bindings: display: bridge: simple: Add data-enable-active to dumb-vga-dac Leonardo Costa
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Leonardo Costa @ 2026-10-19 10:17 UTC (permalink / raw)
To: Andrzej Hajda, Neil Armstrong, Robert Foss, Laurent Pinchart,
Jonas Karlman, Jernej Skrabec, Luca Ceresoli, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Frank Li, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam
Cc: dri-devel, devicetree, linux-kernel, imx, linux-arm-kernel,
Leonardo Costa
This series adds a device tree overlay that enables the VGA output on Apalis
iMX6, which is driven from a parallel RGB interface passing through a
non-programmable video DAC.
The video DAC is a simple resistor network gated by an active-low
data-enable signal. For the bridge to work properly, this series also
changes the following in the dt-bindings and simple-bridge driver:
- dt-bindings: Add the existing data-enable-active property from
video-interfaces.yaml to the simple-bridge binding. The property is
read from the bridge's input endpoint. This allows a dumb-vga-dac to
specify a data-enable signal polarity.
- simple-bridge: Read the data-enable-active property and fill out the
bridge's input bus flags accordingly. The property is ignored if the
bridge already has its own timings struct defined, to not interfere
with its existing settings.
This change depends on another patch, and should be applied after it:
- https://lore.kernel.org/all/20261002-v1-simple-bridge-atomic-check-v1-1-ef5d8332b078@toradex.com/T/#u
Adds the atomic_check function to the simple-bridge driver, which
allows the data-enable bus flag to be propagated through the DRM
pipeline. This is necessary for the VGA to work correctly on the
Apalis iMX6.
Changes in v2:
- Introduce the data-enable-active property.
- Describe the VGA bridge on the Apalis iMX6 as a dumb-vga-dac using
the data-enable-active property to specify the DE signal polarity,
instead of using a dedicated compatible.
- Link to v1: https://lore.kernel.org/all/as-heYw7PKLPm3yH@SMW015318/T/#u
Signed-off-by: Leonardo Costa <leonardo.costa@toradex.com>
---
Leonardo Costa (3):
dt-bindings: display: bridge: simple: Add data-enable-active to dumb-vga-dac
drm/bridge: simple-bridge: Support data-enable-active endpoint property
ARM: dts: imx6q-apalis: Add VGA overlay
.../bindings/display/bridge/simple-bridge.yaml | 28 +++++++-
arch/arm/boot/dts/nxp/imx/Makefile | 21 ++++++
.../boot/dts/nxp/imx/imx6q-apalis-eval-vga.dtso | 80 ++++++++++++++++++++++
drivers/gpu/drm/bridge/simple-bridge.c | 21 +++++-
4 files changed, 148 insertions(+), 2 deletions(-)
---
base-commit: f33c2a109da4a527ed3103acb649a88e88cf368c
change-id: 20261014-v2-apalis-imx6-enable-vga-450f5777a476
Best regards,
--
Leonardo Costa <leonardo.costa@toradex.com>
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v2 1/3] dt-bindings: display: bridge: simple: Add data-enable-active to dumb-vga-dac
2026-10-19 10:17 [PATCH v2 0/3] Add VGA support for Apalis iMX6 Leonardo Costa
@ 2026-10-19 10:17 ` Leonardo Costa
2026-10-19 19:42 ` Frank Li
2026-10-19 10:17 ` [PATCH v2 2/3] drm/bridge: simple-bridge: Support data-enable-active endpoint property Leonardo Costa
2026-10-19 10:17 ` [PATCH v2 3/3] ARM: dts: imx6q-apalis: Add VGA overlay Leonardo Costa
2 siblings, 1 reply; 7+ messages in thread
From: Leonardo Costa @ 2026-10-19 10:17 UTC (permalink / raw)
To: Andrzej Hajda, Neil Armstrong, Robert Foss, Laurent Pinchart,
Jonas Karlman, Jernej Skrabec, Luca Ceresoli, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Frank Li, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam
Cc: dri-devel, devicetree, linux-kernel, imx, linux-arm-kernel,
Leonardo Costa
From: Leonardo Costa <leonardo.costa@toradex.com>
Some simple VGA DACs may include a data-enable input that must be driven
at a specific polarity. Add the data-enable-active property from
video-interfaces to the input endpoint to describe that polarity.
Signed-off-by: Leonardo Costa <leonardo.costa@toradex.com>
---
.../bindings/display/bridge/simple-bridge.yaml | 28 +++++++++++++++++++++-
1 file changed, 27 insertions(+), 1 deletion(-)
diff --git a/Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml b/Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml
index 7636c24906ba..b1b23d41245d 100644
--- a/Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml
+++ b/Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml
@@ -43,9 +43,18 @@ properties:
properties:
port@0:
- $ref: /schemas/graph.yaml#/properties/port
+ $ref: /schemas/graph.yaml#/$defs/port-base
+ unevaluatedProperties: false
description: The bridge input
+ properties:
+ endpoint:
+ $ref: /schemas/media/video-interfaces.yaml
+ unevaluatedProperties: false
+
+ properties:
+ data-enable-active: true
+
port@1:
$ref: /schemas/graph.yaml#/properties/port
description: The bridge output
@@ -65,6 +74,23 @@ required:
- compatible
- ports
+allOf:
+ - if:
+ not:
+ properties:
+ compatible:
+ contains:
+ const: dumb-vga-dac
+ then:
+ properties:
+ ports:
+ properties:
+ port@0:
+ properties:
+ endpoint:
+ properties:
+ data-enable-active: false
+
additionalProperties: false
examples:
--
2.43.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v2 2/3] drm/bridge: simple-bridge: Support data-enable-active endpoint property
2026-10-19 10:17 [PATCH v2 0/3] Add VGA support for Apalis iMX6 Leonardo Costa
2026-10-19 10:17 ` [PATCH v2 1/3] dt-bindings: display: bridge: simple: Add data-enable-active to dumb-vga-dac Leonardo Costa
@ 2026-10-19 10:17 ` Leonardo Costa
2026-10-19 19:50 ` Frank Li
2026-10-19 10:17 ` [PATCH v2 3/3] ARM: dts: imx6q-apalis: Add VGA overlay Leonardo Costa
2 siblings, 1 reply; 7+ messages in thread
From: Leonardo Costa @ 2026-10-19 10:17 UTC (permalink / raw)
To: Andrzej Hajda, Neil Armstrong, Robert Foss, Laurent Pinchart,
Jonas Karlman, Jernej Skrabec, Luca Ceresoli, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Frank Li, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam
Cc: dri-devel, devicetree, linux-kernel, imx, linux-arm-kernel,
Leonardo Costa
From: Leonardo Costa <leonardo.costa@toradex.com>
Some simple bridges, such as a resistor ladder DAC, may include a
data-enable input that must be driven at a specific polarity.
Read the data-enable-active property from the input endpoint and fill
the bridge's input bus flags accordingly, so the upstream encoder drives
DE with the required polarity. The property is applied only if the
bridge doesn't provide its own timings struct.
Signed-off-by: Leonardo Costa <leonardo.costa@toradex.com>
---
drivers/gpu/drm/bridge/simple-bridge.c | 21 ++++++++++++++++++++-
1 file changed, 20 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/bridge/simple-bridge.c b/drivers/gpu/drm/bridge/simple-bridge.c
index 848c2df2a276..c5301295658a 100644
--- a/drivers/gpu/drm/bridge/simple-bridge.c
+++ b/drivers/gpu/drm/bridge/simple-bridge.c
@@ -183,6 +183,9 @@ static int simple_bridge_probe(struct platform_device *pdev)
{
struct simple_bridge *sbridge;
struct device_node *remote;
+ struct device_node *ep;
+ bool de_present;
+ u32 de;
sbridge = devm_drm_bridge_alloc(&pdev->dev, struct simple_bridge,
bridge, &simple_bridge_bridge_funcs);
@@ -220,10 +223,26 @@ static int simple_bridge_probe(struct platform_device *pdev)
return dev_err_probe(&pdev->dev, PTR_ERR(sbridge->enable),
"Unable to retrieve enable GPIO\n");
- /* Register the bridge. */
sbridge->bridge.of_node = pdev->dev.of_node;
sbridge->bridge.timings = sbridge->info->timings;
+ ep = of_graph_get_endpoint_by_regs(pdev->dev.of_node, 0, -1);
+ de_present = !of_property_read_u32(ep, "data-enable-active", &de);
+ of_node_put(ep);
+
+ if (de_present && !sbridge->bridge.timings) {
+ struct drm_bridge_timings *timings;
+
+ timings = devm_kzalloc(&pdev->dev, sizeof(*timings), GFP_KERNEL);
+ if (!timings)
+ return -ENOMEM;
+
+ timings->input_bus_flags = de ? DRM_BUS_FLAG_DE_HIGH :
+ DRM_BUS_FLAG_DE_LOW;
+ sbridge->bridge.timings = timings;
+ }
+
+ /* Register the bridge. */
return devm_drm_bridge_add(&pdev->dev, &sbridge->bridge);
}
--
2.43.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v2 3/3] ARM: dts: imx6q-apalis: Add VGA overlay
2026-10-19 10:17 [PATCH v2 0/3] Add VGA support for Apalis iMX6 Leonardo Costa
2026-10-19 10:17 ` [PATCH v2 1/3] dt-bindings: display: bridge: simple: Add data-enable-active to dumb-vga-dac Leonardo Costa
2026-10-19 10:17 ` [PATCH v2 2/3] drm/bridge: simple-bridge: Support data-enable-active endpoint property Leonardo Costa
@ 2026-10-19 10:17 ` Leonardo Costa
2026-10-19 19:37 ` Frank Li
2 siblings, 1 reply; 7+ messages in thread
From: Leonardo Costa @ 2026-10-19 10:17 UTC (permalink / raw)
To: Andrzej Hajda, Neil Armstrong, Robert Foss, Laurent Pinchart,
Jonas Karlman, Jernej Skrabec, Luca Ceresoli, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Frank Li, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam
Cc: dri-devel, devicetree, linux-kernel, imx, linux-arm-kernel,
Leonardo Costa
From: Leonardo Costa <leonardo.costa@toradex.com>
Add a device tree overlay for the VGA output available on the Apalis
Evaluation Board, which is driven from a parallel RGB interface passing
through a non-programmable video DAC to a VGA connector, without VESA
DDC I2C signals.
The non-programmable video DAC consists of a simple resistor ladder that
converts the digital 16-bit RGB signal to VGA. The VGA output is gated by
an active-low data-enable signal.
The overlay is also combined with the various Apalis Evaluation Board
device trees to provide ready-to-use DTBs.
Signed-off-by: Leonardo Costa <leonardo.costa@toradex.com>
---
arch/arm/boot/dts/nxp/imx/Makefile | 21 ++++++
.../boot/dts/nxp/imx/imx6q-apalis-eval-vga.dtso | 80 ++++++++++++++++++++++
2 files changed, 101 insertions(+)
diff --git a/arch/arm/boot/dts/nxp/imx/Makefile b/arch/arm/boot/dts/nxp/imx/Makefile
index b5fad2ba764c..9c218260fdcb 100644
--- a/arch/arm/boot/dts/nxp/imx/Makefile
+++ b/arch/arm/boot/dts/nxp/imx/Makefile
@@ -60,6 +60,22 @@ dtb-$(CONFIG_SOC_IMX53) += \
imx53-qsb-hdmi-dtbs := imx53-qsb.dtb imx53-qsb-hdmi.dtbo
imx53-qsrb-hdmi-dtbs := imx53-qsrb.dtb imx53-qsb-hdmi.dtbo
+imx6q-apalis-eval-v1.2-vga-dtbs := \
+ imx6q-apalis-eval-v1.2.dtb \
+ imx6q-apalis-eval-vga.dtbo
+
+imx6q-apalis-eval-vga-dtbs := \
+ imx6q-apalis-eval.dtb \
+ imx6q-apalis-eval-vga.dtbo
+
+imx6q-apalis-v1.2-eval-v1.2-vga-dtbs := \
+ imx6q-apalis-v1.2-eval-v1.2.dtb \
+ imx6q-apalis-eval-vga.dtbo
+
+imx6q-apalis-v1.2-eval-vga-dtbs := \
+ imx6q-apalis-v1.2-eval.dtb \
+ imx6q-apalis-eval-vga.dtbo
+
imx6qdl-dhcom-pdk2-overlay-497-200-x12-dtbs := \
imx6q-dhcom-pdk2.dtb \
imx6qdl-dhcom-pdk2-overlay-497-200-x12.dtbo
@@ -186,11 +202,16 @@ dtb-$(CONFIG_SOC_IMX6Q) += \
imx6dl-yapp4-ursa.dtb \
imx6q-apalis-eval.dtb \
imx6q-apalis-eval-v1.2.dtb \
+ imx6q-apalis-eval-v1.2-vga.dtb \
+ imx6q-apalis-eval-vga.dtb \
+ imx6q-apalis-eval-vga.dtbo \
imx6q-apalis-ixora.dtb \
imx6q-apalis-ixora-v1.1.dtb \
imx6q-apalis-ixora-v1.2.dtb \
imx6q-apalis-v1.2-eval.dtb \
imx6q-apalis-v1.2-eval-v1.2.dtb \
+ imx6q-apalis-v1.2-eval-v1.2-vga.dtb \
+ imx6q-apalis-v1.2-eval-vga.dtb \
imx6q-apalis-v1.2-ixora.dtb \
imx6q-apalis-v1.2-ixora-v1.1.dtb \
imx6q-apalis-v1.2-ixora-v1.2.dtb \
diff --git a/arch/arm/boot/dts/nxp/imx/imx6q-apalis-eval-vga.dtso b/arch/arm/boot/dts/nxp/imx/imx6q-apalis-eval-vga.dtso
new file mode 100644
index 000000000000..991c2b7c2777
--- /dev/null
+++ b/arch/arm/boot/dts/nxp/imx/imx6q-apalis-eval-vga.dtso
@@ -0,0 +1,80 @@
+// SPDX-License-Identifier: GPL-2.0-only OR MIT
+/*
+ * Copyright (c) Toradex
+ *
+ * VGA output connected to a parallel RGB LCD interface through a
+ * non-programmable video DAC with a VGA connector.
+ *
+ * The VGA output is available on the Apalis Evaluation Board without VESA DDC
+ * I2C signals.
+ */
+
+/dts-v1/;
+/plugin/;
+
+&{/} {
+ disp1 {
+ compatible = "fsl,imx-parallel-display";
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_ipu2_vdac>;
+ #address-cells = <1>;
+ #size-cells = <0>;
+ interface-pix-fmt = "rgb565";
+
+ port@0 {
+ reg = <0>;
+
+ vga_display_in: endpoint {
+ remote-endpoint = <&ipu2_di0_disp0>;
+ };
+ };
+
+ port@1 {
+ reg = <1>;
+
+ vga_display_out: endpoint {
+ remote-endpoint = <&vga_enc_in>;
+ };
+ };
+ };
+
+ vga-encoder {
+ compatible = "dumb-vga-dac";
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ port@0 {
+ reg = <0>;
+
+ vga_enc_in: endpoint {
+ data-enable-active = <0>;
+ remote-endpoint = <&vga_display_out>;
+ };
+ };
+
+ port@1 {
+ reg = <1>;
+
+ vga_enc_out: endpoint {
+ remote-endpoint = <&vga_connector_in>;
+ };
+ };
+ };
+ };
+
+ vga-connector {
+ compatible = "vga-connector";
+
+ port {
+ vga_connector_in: endpoint {
+ remote-endpoint = <&vga_enc_out>;
+ };
+ };
+ };
+};
+
+&ipu2_di0_disp0 {
+ remote-endpoint = <&vga_display_in>;
+};
--
2.43.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v2 3/3] ARM: dts: imx6q-apalis: Add VGA overlay
2026-10-19 10:17 ` [PATCH v2 3/3] ARM: dts: imx6q-apalis: Add VGA overlay Leonardo Costa
@ 2026-10-19 19:37 ` Frank Li
0 siblings, 0 replies; 7+ messages in thread
From: Frank Li @ 2026-10-19 19:37 UTC (permalink / raw)
To: Leonardo Costa
Cc: Andrzej Hajda, Neil Armstrong, Robert Foss, Laurent Pinchart,
Jonas Karlman, Jernej Skrabec, Luca Ceresoli, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Frank Li, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
dri-devel, devicetree, linux-kernel, imx, linux-arm-kernel,
Leonardo Costa
On Mon, Oct 19, 2026 at 07:17:16AM -0300, Leonardo Costa wrote:
> From: Leonardo Costa <leonardo.costa@toradex.com>
>
> Add a device tree overlay for the VGA output available on the Apalis
> Evaluation Board, which is driven from a parallel RGB interface passing
> through a non-programmable video DAC to a VGA connector, without VESA
> DDC I2C signals.
>
> The non-programmable video DAC consists of a simple resistor ladder that
> converts the digital 16-bit RGB signal to VGA. The VGA output is gated by
> an active-low data-enable signal.
>
> The overlay is also combined with the various Apalis Evaluation Board
> device trees to provide ready-to-use DTBs.
>
> Signed-off-by: Leonardo Costa <leonardo.costa@toradex.com>
> ---
> arch/arm/boot/dts/nxp/imx/Makefile | 21 ++++++
> .../boot/dts/nxp/imx/imx6q-apalis-eval-vga.dtso | 80 ++++++++++++++++++++++
what's difference with
https://lore.kernel.org/imx/20261019-colibri-imx6-overlays-v1-5-e4d028727382@toradex.com/T/#u
Is it possible share one dtso also?
Frank
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2 1/3] dt-bindings: display: bridge: simple: Add data-enable-active to dumb-vga-dac
2026-10-19 10:17 ` [PATCH v2 1/3] dt-bindings: display: bridge: simple: Add data-enable-active to dumb-vga-dac Leonardo Costa
@ 2026-10-19 19:42 ` Frank Li
0 siblings, 0 replies; 7+ messages in thread
From: Frank Li @ 2026-10-19 19:42 UTC (permalink / raw)
To: Leonardo Costa
Cc: Andrzej Hajda, Neil Armstrong, Robert Foss, Laurent Pinchart,
Jonas Karlman, Jernej Skrabec, Luca Ceresoli, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Frank Li, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
dri-devel, devicetree, linux-kernel, imx, linux-arm-kernel,
Leonardo Costa
On Mon, Oct 19, 2026 at 07:17:14AM -0300, Leonardo Costa wrote:
> From: Leonardo Costa <leonardo.costa@toradex.com>
>
> Some simple VGA DACs may include a data-enable input that must be driven
> at a specific polarity. Add the data-enable-active property from
> video-interfaces to the input endpoint to describe that polarity.
>
> Signed-off-by: Leonardo Costa <leonardo.costa@toradex.com>
> ---
> .../bindings/display/bridge/simple-bridge.yaml | 28 +++++++++++++++++++++-
> 1 file changed, 27 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml b/Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml
> index 7636c24906ba..b1b23d41245d 100644
> --- a/Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml
> +++ b/Documentation/devicetree/bindings/display/bridge/simple-bridge.yaml
> @@ -43,9 +43,18 @@ properties:
>
> properties:
> port@0:
> - $ref: /schemas/graph.yaml#/properties/port
> + $ref: /schemas/graph.yaml#/$defs/port-base
> + unevaluatedProperties: false
> description: The bridge input
>
> + properties:
> + endpoint:
> + $ref: /schemas/media/video-interfaces.yaml
> + unevaluatedProperties: false
> +
> + properties:
> + data-enable-active: true
> +
suppose needn't it because unevaluatedProperties: false, which allow all
property in video-interfaces.yaml.
If you only want to enable one property, should be
additionalProperties: false
but I think unevaluatedProperties: false make sense and needn't below if
branch.
Frank
> port@1:
> $ref: /schemas/graph.yaml#/properties/port
> description: The bridge output
> @@ -65,6 +74,23 @@ required:
> - compatible
> - ports
>
> +allOf:
> + - if:
> + not:
> + properties:
> + compatible:
> + contains:
> + const: dumb-vga-dac
> + then:
> + properties:
> + ports:
> + properties:
> + port@0:
> + properties:
> + endpoint:
> + properties:
> + data-enable-active: false
> +
> additionalProperties: false
>
> examples:
>
> --
> 2.43.0
>
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2 2/3] drm/bridge: simple-bridge: Support data-enable-active endpoint property
2026-10-19 10:17 ` [PATCH v2 2/3] drm/bridge: simple-bridge: Support data-enable-active endpoint property Leonardo Costa
@ 2026-10-19 19:50 ` Frank Li
0 siblings, 0 replies; 7+ messages in thread
From: Frank Li @ 2026-10-19 19:50 UTC (permalink / raw)
To: Leonardo Costa
Cc: Andrzej Hajda, Neil Armstrong, Robert Foss, Laurent Pinchart,
Jonas Karlman, Jernej Skrabec, Luca Ceresoli, David Airlie,
Simona Vetter, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Frank Li, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
dri-devel, devicetree, linux-kernel, imx, linux-arm-kernel,
Leonardo Costa
On Mon, Oct 19, 2026 at 07:17:15AM -0300, Leonardo Costa wrote:
> From: Leonardo Costa <leonardo.costa@toradex.com>
>
> Some simple bridges, such as a resistor ladder DAC, may include a
> data-enable input that must be driven at a specific polarity.
>
> Read the data-enable-active property from the input endpoint and fill
> the bridge's input bus flags accordingly, so the upstream encoder drives
> DE with the required polarity. The property is applied only if the
> bridge doesn't provide its own timings struct.
>
> Signed-off-by: Leonardo Costa <leonardo.costa@toradex.com>
> ---
Reviewed-by: Frank Li <Frank.Li@nxp.com>
> drivers/gpu/drm/bridge/simple-bridge.c | 21 ++++++++++++++++++++-
> 1 file changed, 20 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/bridge/simple-bridge.c b/drivers/gpu/drm/bridge/simple-bridge.c
> index 848c2df2a276..c5301295658a 100644
> --- a/drivers/gpu/drm/bridge/simple-bridge.c
> +++ b/drivers/gpu/drm/bridge/simple-bridge.c
> @@ -183,6 +183,9 @@ static int simple_bridge_probe(struct platform_device *pdev)
> {
> struct simple_bridge *sbridge;
> struct device_node *remote;
> + struct device_node *ep;
> + bool de_present;
> + u32 de;
>
> sbridge = devm_drm_bridge_alloc(&pdev->dev, struct simple_bridge,
> bridge, &simple_bridge_bridge_funcs);
> @@ -220,10 +223,26 @@ static int simple_bridge_probe(struct platform_device *pdev)
> return dev_err_probe(&pdev->dev, PTR_ERR(sbridge->enable),
> "Unable to retrieve enable GPIO\n");
>
> - /* Register the bridge. */
> sbridge->bridge.of_node = pdev->dev.of_node;
> sbridge->bridge.timings = sbridge->info->timings;
>
> + ep = of_graph_get_endpoint_by_regs(pdev->dev.of_node, 0, -1);
> + de_present = !of_property_read_u32(ep, "data-enable-active", &de);
> + of_node_put(ep);
> +
> + if (de_present && !sbridge->bridge.timings) {
> + struct drm_bridge_timings *timings;
> +
> + timings = devm_kzalloc(&pdev->dev, sizeof(*timings), GFP_KERNEL);
> + if (!timings)
> + return -ENOMEM;
> +
> + timings->input_bus_flags = de ? DRM_BUS_FLAG_DE_HIGH :
> + DRM_BUS_FLAG_DE_LOW;
> + sbridge->bridge.timings = timings;
> + }
> +
> + /* Register the bridge. */
> return devm_drm_bridge_add(&pdev->dev, &sbridge->bridge);
> }
>
>
> --
> 2.43.0
>
>
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2026-10-19 19:51 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-19 10:17 [PATCH v2 0/3] Add VGA support for Apalis iMX6 Leonardo Costa
2026-10-19 10:17 ` [PATCH v2 1/3] dt-bindings: display: bridge: simple: Add data-enable-active to dumb-vga-dac Leonardo Costa
2026-10-19 19:42 ` Frank Li
2026-10-19 10:17 ` [PATCH v2 2/3] drm/bridge: simple-bridge: Support data-enable-active endpoint property Leonardo Costa
2026-10-19 19:50 ` Frank Li
2026-10-19 10:17 ` [PATCH v2 3/3] ARM: dts: imx6q-apalis: Add VGA overlay Leonardo Costa
2026-10-19 19:37 ` Frank Li
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox