* [PATCH] dt-bindings: lcdif: Add support for specifying display with timings
@ 2024-09-23 13:57 Lukasz Majewski
2024-09-23 17:53 ` Marek Vasut
2024-09-24 23:03 ` Rob Herring
0 siblings, 2 replies; 5+ messages in thread
From: Lukasz Majewski @ 2024-09-23 13:57 UTC (permalink / raw)
To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Marek Vasut,
Stefan Agner
Cc: Maarten Lankhorst, Fabio Estevam, Maxime Ripard,
Thomas Zimmermann, David Airlie, Simona Vetter, dri-devel,
devicetree, linux-kernel, Lukasz Majewski
Up till now the fsl,lcdif.yaml was requiring the "port" property as a
must have to specify the display interface on iMX devices.
However, it shall also be possible to specify the display only with
passing its timing parameters (h* and v* ones) via "display" property:
(as in
Documentation/devicetree/bindings/display/panel/display-timings.yaml).
Such approach has already been used (also in the mainline) with several
imx28, imx5x and imx6q devices.
This change allows them to pass the DT_SCHEMA check without issues.
Signed-off-by: Lukasz Majewski <lukma@denx.de>
---
.../bindings/display/fsl,lcdif.yaml | 51 ++++++++++++++++++-
1 file changed, 49 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/display/fsl,lcdif.yaml b/Documentation/devicetree/bindings/display/fsl,lcdif.yaml
index 8e3a98aeec32..14bb64b5b72d 100644
--- a/Documentation/devicetree/bindings/display/fsl,lcdif.yaml
+++ b/Documentation/devicetree/bindings/display/fsl,lcdif.yaml
@@ -50,6 +50,10 @@ properties:
- const: disp_axi
minItems: 1
+ display:
+ $ref: /schemas/types.yaml#/definitions/phandle
+ description: The phandle for display timing information
+
dmas:
items:
- description: DMA specifier for the RX DMA channel.
@@ -64,6 +68,9 @@ properties:
- description: LCDIF Error interrupt
minItems: 1
+ lcd-supply:
+ description: Regulator for LCD supply voltage.
+
power-domains:
maxItems: 1
@@ -76,7 +83,10 @@ required:
- reg
- clocks
- interrupts
- - port
+
+patternProperties:
+ 'display([0-9])':
+ description: Node with display timing parameters
additionalProperties: false
@@ -197,5 +207,42 @@ examples:
};
};
};
-
+ - |
+ lcdif: lcdif@80030000 {
+ compatible = "fsl,imx28-lcdif";
+ reg = <0x80030000 0x2000>;
+ interrupts = <38>;
+ clocks = <&clks 55>;
+ dmas = <&dma_apbh 13>;
+ dma-names = "rx";
+ pinctrl-names = "default";
+ pinctrl-0 = <&lcdif_24bit_pins_a>, <&lcdif_sync_pins_bttc>,
+ <&lcdif_reset_pins_bttc>;
+ lcd-supply = <®_3v3>;
+ display = <&display0>;
+ status = "okay";
+
+ display0: display0 {
+ bits-per-pixel = <32>;
+ bus-width = <24>;
+ display-timings {
+ native-mode = <&timing0>;
+ timing0: timing0 {
+ clock-frequency = <6500000>;
+ hactive = <320>;
+ vactive = <240>;
+ hfront-porch = <20>;
+ hback-porch = <38>;
+ hsync-len = <30>;
+ vfront-porch = <4>;
+ vback-porch = <14>;
+ vsync-len = <4>;
+ hsync-active = <0>;
+ vsync-active = <0>;
+ de-active = <0>;
+ pixelclk-active = <1>;
+ };
+ };
+ };
+ };
...
--
2.39.2
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] dt-bindings: lcdif: Add support for specifying display with timings
2024-09-23 13:57 [PATCH] dt-bindings: lcdif: Add support for specifying display with timings Lukasz Majewski
@ 2024-09-23 17:53 ` Marek Vasut
2024-09-24 22:57 ` Rob Herring
2024-09-24 23:03 ` Rob Herring
1 sibling, 1 reply; 5+ messages in thread
From: Marek Vasut @ 2024-09-23 17:53 UTC (permalink / raw)
To: Lukasz Majewski, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Stefan Agner
Cc: Maarten Lankhorst, Fabio Estevam, Maxime Ripard,
Thomas Zimmermann, David Airlie, Simona Vetter, dri-devel,
devicetree, linux-kernel
On 9/23/24 3:57 PM, Lukasz Majewski wrote:
> Up till now the fsl,lcdif.yaml was requiring the "port" property as a
> must have to specify the display interface on iMX devices.
>
> However, it shall also be possible to specify the display only with
> passing its timing parameters (h* and v* ones) via "display" property:
> (as in
> Documentation/devicetree/bindings/display/panel/display-timings.yaml).
Timings should go into panel node, not into scanout engine node.
See e.g. panel-timings in arch/arm64/boot/dts/freescale/imx8mm-phg.dts ,
in your case the compatible might be "panel-dpi" .
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] dt-bindings: lcdif: Add support for specifying display with timings
2024-09-23 17:53 ` Marek Vasut
@ 2024-09-24 22:57 ` Rob Herring
2024-09-24 23:44 ` Marek Vasut
0 siblings, 1 reply; 5+ messages in thread
From: Rob Herring @ 2024-09-24 22:57 UTC (permalink / raw)
To: Marek Vasut
Cc: Lukasz Majewski, Krzysztof Kozlowski, Conor Dooley, Stefan Agner,
Maarten Lankhorst, Fabio Estevam, Maxime Ripard,
Thomas Zimmermann, David Airlie, Simona Vetter, dri-devel,
devicetree, linux-kernel
On Mon, Sep 23, 2024 at 07:53:57PM +0200, Marek Vasut wrote:
> On 9/23/24 3:57 PM, Lukasz Majewski wrote:
> > Up till now the fsl,lcdif.yaml was requiring the "port" property as a
> > must have to specify the display interface on iMX devices.
> >
> > However, it shall also be possible to specify the display only with
> > passing its timing parameters (h* and v* ones) via "display" property:
> > (as in
> > Documentation/devicetree/bindings/display/panel/display-timings.yaml).
>
> Timings should go into panel node, not into scanout engine node.
>
> See e.g. panel-timings in arch/arm64/boot/dts/freescale/imx8mm-phg.dts , in
> your case the compatible might be "panel-dpi" .
I agree, but if this is already in use, we should allow it. We can mark
it deprecated though.
Rob
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] dt-bindings: lcdif: Add support for specifying display with timings
2024-09-23 13:57 [PATCH] dt-bindings: lcdif: Add support for specifying display with timings Lukasz Majewski
2024-09-23 17:53 ` Marek Vasut
@ 2024-09-24 23:03 ` Rob Herring
1 sibling, 0 replies; 5+ messages in thread
From: Rob Herring @ 2024-09-24 23:03 UTC (permalink / raw)
To: Lukasz Majewski
Cc: Krzysztof Kozlowski, Conor Dooley, Marek Vasut, Stefan Agner,
Maarten Lankhorst, Fabio Estevam, Maxime Ripard,
Thomas Zimmermann, David Airlie, Simona Vetter, dri-devel,
devicetree, linux-kernel
On Mon, Sep 23, 2024 at 03:57:44PM +0200, Lukasz Majewski wrote:
> Up till now the fsl,lcdif.yaml was requiring the "port" property as a
> must have to specify the display interface on iMX devices.
>
> However, it shall also be possible to specify the display only with
> passing its timing parameters (h* and v* ones) via "display" property:
> (as in
> Documentation/devicetree/bindings/display/panel/display-timings.yaml).
>
> Such approach has already been used (also in the mainline) with several
> imx28, imx5x and imx6q devices.
>
> This change allows them to pass the DT_SCHEMA check without issues.
>
> Signed-off-by: Lukasz Majewski <lukma@denx.de>
> ---
> .../bindings/display/fsl,lcdif.yaml | 51 ++++++++++++++++++-
> 1 file changed, 49 insertions(+), 2 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/display/fsl,lcdif.yaml b/Documentation/devicetree/bindings/display/fsl,lcdif.yaml
> index 8e3a98aeec32..14bb64b5b72d 100644
> --- a/Documentation/devicetree/bindings/display/fsl,lcdif.yaml
> +++ b/Documentation/devicetree/bindings/display/fsl,lcdif.yaml
> @@ -50,6 +50,10 @@ properties:
> - const: disp_axi
> minItems: 1
>
> + display:
> + $ref: /schemas/types.yaml#/definitions/phandle
> + description: The phandle for display timing information
> +
> dmas:
> items:
> - description: DMA specifier for the RX DMA channel.
> @@ -64,6 +68,9 @@ properties:
> - description: LCDIF Error interrupt
> minItems: 1
>
> + lcd-supply:
> + description: Regulator for LCD supply voltage.
> +
> power-domains:
> maxItems: 1
>
> @@ -76,7 +83,10 @@ required:
> - reg
> - clocks
> - interrupts
> - - port
> +
> +patternProperties:
> + 'display([0-9])':
This allows for 'foodisplay0bar'. You need start and end anchors.
And it doesn't even have to be a node because there are no contraints
here. You need 'type: object' and then to define what's in the node.
> + description: Node with display timing parameters
>
> additionalProperties: false
>
> @@ -197,5 +207,42 @@ examples:
> };
> };
> };
> -
> + - |
> + lcdif: lcdif@80030000 {
> + compatible = "fsl,imx28-lcdif";
> + reg = <0x80030000 0x2000>;
> + interrupts = <38>;
> + clocks = <&clks 55>;
> + dmas = <&dma_apbh 13>;
> + dma-names = "rx";
> + pinctrl-names = "default";
> + pinctrl-0 = <&lcdif_24bit_pins_a>, <&lcdif_sync_pins_bttc>,
> + <&lcdif_reset_pins_bttc>;
> + lcd-supply = <®_3v3>;
> + display = <&display0>;
> + status = "okay";
Don't need status in the examples.
> +
> + bits-per-pixel = <32>;
> + bus-width = <24>;
> + display-timings {
> + native-mode = <&timing0>;
> + timing0: timing0 {
> + clock-frequency = <6500000>;
> + hactive = <320>;
> + vactive = <240>;
> + hfront-porch = <20>;
> + hback-porch = <38>;
> + hsync-len = <30>;
> + vfront-porch = <4>;
> + vback-porch = <14>;
> + vsync-len = <4>;
> + hsync-active = <0>;
> + vsync-active = <0>;
> + de-active = <0>;
> + pixelclk-active = <1>;
> + };
> + };
> + };
> + };
> ...
> --
> 2.39.2
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] dt-bindings: lcdif: Add support for specifying display with timings
2024-09-24 22:57 ` Rob Herring
@ 2024-09-24 23:44 ` Marek Vasut
0 siblings, 0 replies; 5+ messages in thread
From: Marek Vasut @ 2024-09-24 23:44 UTC (permalink / raw)
To: Rob Herring
Cc: Lukasz Majewski, Krzysztof Kozlowski, Conor Dooley, Stefan Agner,
Maarten Lankhorst, Fabio Estevam, Maxime Ripard,
Thomas Zimmermann, David Airlie, Simona Vetter, dri-devel,
devicetree, linux-kernel
On 9/25/24 12:57 AM, Rob Herring wrote:
> On Mon, Sep 23, 2024 at 07:53:57PM +0200, Marek Vasut wrote:
>> On 9/23/24 3:57 PM, Lukasz Majewski wrote:
>>> Up till now the fsl,lcdif.yaml was requiring the "port" property as a
>>> must have to specify the display interface on iMX devices.
>>>
>>> However, it shall also be possible to specify the display only with
>>> passing its timing parameters (h* and v* ones) via "display" property:
>>> (as in
>>> Documentation/devicetree/bindings/display/panel/display-timings.yaml).
>>
>> Timings should go into panel node, not into scanout engine node.
>>
>> See e.g. panel-timings in arch/arm64/boot/dts/freescale/imx8mm-phg.dts , in
>> your case the compatible might be "panel-dpi" .
>
> I agree, but if this is already in use, we should allow it. We can mark
> it deprecated though.
I don't think it is in use yet, at least not in upstream, so let's not
allow this.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2024-09-24 23:44 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-23 13:57 [PATCH] dt-bindings: lcdif: Add support for specifying display with timings Lukasz Majewski
2024-09-23 17:53 ` Marek Vasut
2024-09-24 22:57 ` Rob Herring
2024-09-24 23:44 ` Marek Vasut
2024-09-24 23:03 ` Rob Herring
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).