From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: "Marek Vasut" <marex@denx.de>,
devicetree@vger.kernel.org, "Guido Günther" <agx@sigxcpu.org>,
dri-devel@lists.freedesktop.org,
"Rob Herring" <robh+dt@kernel.org>,
"Pengutronix Kernel Team" <kernel@pengutronix.de>,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 1/8] dt-bindings: display: mxsfb: Convert binding to YAML
Date: Mon, 17 Aug 2020 03:00:49 +0300 [thread overview]
Message-ID: <20200817000049.GB7729@pendragon.ideasonboard.com> (raw)
In-Reply-To: <20200816062242.GB1201814@ravnborg.org>
Hi Sam,
On Sun, Aug 16, 2020 at 08:22:42AM +0200, Sam Ravnborg wrote:
> Hi Laurent.
>
> Good to see one of the imx bindings migrating to yaml.
>
> On Thu, Aug 13, 2020 at 04:29:03AM +0300, Laurent Pinchart wrote:
> > Convert the mxsfb binding to YAML. The deprecated binding is dropped, as
> > neither the DT sources nor the driver support it anymore.
> >
> > The compatible strings are messy, and DT sources use different kinds of
> > combination of documented and undocumented values. Keep it simple for
> > now, and update the example to make it valid. Aligning the binding with
> > the existing DT sources will be performed separately.
> >
> > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
>
> Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
> But see below for a few nits
>
> > ---
> > .../devicetree/bindings/display/mxsfb.txt | 87 -------------
> > .../devicetree/bindings/display/mxsfb.yaml | 115 ++++++++++++++++++
> > MAINTAINERS | 2 +-
> > 3 files changed, 116 insertions(+), 88 deletions(-)
> > delete mode 100644 Documentation/devicetree/bindings/display/mxsfb.txt
> > create mode 100644 Documentation/devicetree/bindings/display/mxsfb.yaml
> >
> > diff --git a/Documentation/devicetree/bindings/display/mxsfb.txt b/Documentation/devicetree/bindings/display/mxsfb.txt
> > deleted file mode 100644
> > index c985871c46b3..000000000000
> > --- a/Documentation/devicetree/bindings/display/mxsfb.txt
> > +++ /dev/null
> > @@ -1,87 +0,0 @@
> > -* Freescale MXS LCD Interface (LCDIF)
> > -
> > -New bindings:
> > -=============
> > -Required properties:
> > -- compatible: Should be "fsl,imx23-lcdif" for i.MX23.
> > - Should be "fsl,imx28-lcdif" for i.MX28.
> > - Should be "fsl,imx6sx-lcdif" for i.MX6SX.
> > - Should be "fsl,imx8mq-lcdif" for i.MX8MQ.
> > -- reg: Address and length of the register set for LCDIF
> > -- interrupts: Should contain LCDIF interrupt
> > -- clocks: A list of phandle + clock-specifier pairs, one for each
> > - entry in 'clock-names'.
> > -- clock-names: A list of clock names. For MXSFB it should contain:
> > - - "pix" for the LCDIF block clock
> > - - (MX6SX-only) "axi", "disp_axi" for the bus interface clock
> > -
> > -Required sub-nodes:
> > - - port: The connection to an encoder chip.
> > -
> > -Example:
> > -
> > - lcdif1: display-controller@2220000 {
> > - compatible = "fsl,imx6sx-lcdif", "fsl,imx28-lcdif";
> > - reg = <0x02220000 0x4000>;
> > - interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
> > - clocks = <&clks IMX6SX_CLK_LCDIF1_PIX>,
> > - <&clks IMX6SX_CLK_LCDIF_APB>,
> > - <&clks IMX6SX_CLK_DISPLAY_AXI>;
> > - clock-names = "pix", "axi", "disp_axi";
> > -
> > - port {
> > - parallel_out: endpoint {
> > - remote-endpoint = <&panel_in_parallel>;
> > - };
> > - };
> > - };
> > -
> > -Deprecated bindings:
> > -====================
> > -Required properties:
> > -- compatible: Should be "fsl,imx23-lcdif" for i.MX23.
> > - Should be "fsl,imx28-lcdif" for i.MX28.
> > -- reg: Address and length of the register set for LCDIF
> > -- interrupts: Should contain LCDIF interrupts
> > -- display: phandle to display node (see below for details)
> > -
> > -* display node
> > -
> > -Required properties:
> > -- bits-per-pixel: <16> for RGB565, <32> for RGB888/666.
> > -- bus-width: number of data lines. Could be <8>, <16>, <18> or <24>.
> > -
> > -Required sub-node:
> > -- display-timings: Refer to binding doc display-timing.txt for details.
> > -
> > -Examples:
> > -
> > -lcdif@80030000 {
> > - compatible = "fsl,imx28-lcdif";
> > - reg = <0x80030000 2000>;
> > - interrupts = <38 86>;
> > -
> > - display: display {
> > - bits-per-pixel = <32>;
> > - bus-width = <24>;
> > -
> > - display-timings {
> > - native-mode = <&timing0>;
> > - timing0: timing0 {
> > - clock-frequency = <33500000>;
> > - hactive = <800>;
> > - vactive = <480>;
> > - hfront-porch = <164>;
> > - hback-porch = <89>;
> > - hsync-len = <10>;
> > - vback-porch = <23>;
> > - vfront-porch = <10>;
> > - vsync-len = <10>;
> > - hsync-active = <0>;
> > - vsync-active = <0>;
> > - de-active = <1>;
> > - pixelclk-active = <0>;
> > - };
> > - };
> > - };
> > -};
> > diff --git a/Documentation/devicetree/bindings/display/mxsfb.yaml b/Documentation/devicetree/bindings/display/mxsfb.yaml
> > new file mode 100644
> > index 000000000000..202381ec5bb7
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/display/mxsfb.yaml
> > @@ -0,0 +1,115 @@
> > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/display/mxsfb.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Freescale/NXP i.MX LCD Interface (LCDIF)
> > +
> > +maintainers:
> > + - Marek Vasut <marex@denx.de>
> > + - Stefan Agner <stefan@agner.ch>
> > +
> > +description: |
> > + (e)LCDIF display controller found in the Freescale/NXP i.MX SoCs.
> > +
> > +properties:
> > + compatible:
> > + enum:
> > + - fsl,imx23-lcdif
> > + - fsl,imx28-lcdif
> > + - fsl,imx6sx-lcdif
> > + - fsl,imx8mq-lcdif
> > +
> > + reg:
> > + maxItems: 1
> > +
> > + clocks:
> > + items:
> > + - description: Pixel clock
> > + - description: Bus clock
> > + - description: Display AXI clock
> > + minItems: 1
> > +
> > + clock-names:
> > + items:
> > + - const: "pix"
> > + - const: "axi"
> > + - const: "disp_axi"
> > + minItems: 1
> > +
> > + interrupts:
> > + maxItems: 1
> > +
> > + port:
> > + description: The LCDIF output port
> > + type: object
> > +
> > + properties:
> > + endpoint:
> > + type: object
> > +
> > + properties:
> > + remote-endpoint:
> > + $ref: /schemas/types.yaml#/definitions/phandle
> > +
> > + required:
> > + - remote-endpoint
> > +
> > + additionalProperties: false
> > +
> > + additionalProperties: false
> > +
> > +required:
> > + - compatible
> > + - reg
> > + - clocks
> > + - interrupts
> > + - port
> > +
> > +additionalProperties: false
> > +
> > +allOf:
> > + - if:
> > + properties:
> > + compatible:
> > + contains:
> > + const: fsl,imx6sx-lcdif
> > + then:
> > + properties:
> > + clocks:
> > + minItems: 2
> > + maxItems: 3
> > + clock-names:
> > + minItems: 2
> > + maxItems: 3
> > + required:
> > + - clock-names
> > + else:
> > + properties:
> > + clocks:
> > + minItems: 1
> > + clock-names:
> > + minItems: 1
>
> The else parts looks like it is not needed.
> The clock, clock-names properties has minItems: 1 already from above.
Conceptually you're right, this should be maxItems, not minItems.
However, the DT schema checker automatically adds a maxItems property
that equal minItems when only minItems is specified (and the other way
around as well). This is meant to allow shorter notations. I'm not
convinced it's a good idea, but that's the way it is today.
I'll change to maxItems as it's more explicit.
> > +
> > +examples:
> > + - |
> > + #include <dt-bindings/clock/imx6sx-clock.h>
> > + #include <dt-bindings/interrupt-controller/arm-gic.h>
> > +
> > + display-controller@2220000 {
> > + compatible = "fsl,imx6sx-lcdif";
> > + reg = <0x02220000 0x4000>;
> > + interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
> > + clocks = <&clks IMX6SX_CLK_LCDIF1_PIX>,
> > + <&clks IMX6SX_CLK_LCDIF_APB>,
> > + <&clks IMX6SX_CLK_DISPLAY_AXI>;
> > + clock-names = "pix", "axi", "disp_axi";
> > +
> > + port {
> > + endpoint {
> > + remote-endpoint = <&panel_in>;
> > + };
> > + };
> > + };
>
> empty line before "..." - at least most files have it
I'll add that.
> > +...
> > diff --git a/MAINTAINERS b/MAINTAINERS
> > index e3467e88714f..e3fac23383d2 100644
> > --- a/MAINTAINERS
> > +++ b/MAINTAINERS
> > @@ -11757,7 +11757,7 @@ M: Stefan Agner <stefan@agner.ch>
> > L: dri-devel@lists.freedesktop.org
> > S: Supported
> > T: git git://anongit.freedesktop.org/drm/drm-misc
> > -F: Documentation/devicetree/bindings/display/mxsfb.txt
> > +F: Documentation/devicetree/bindings/display/mxsfb.yaml
> > F: drivers/gpu/drm/mxsfb/
> >
> > MYLEX DAC960 PCI RAID Controller
--
Regards,
Laurent Pinchart
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
WARNING: multiple messages have this Message-ID (diff)
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: dri-devel@lists.freedesktop.org, "Marek Vasut" <marex@denx.de>,
devicetree@vger.kernel.org, "Guido Günther" <agx@sigxcpu.org>,
"Rob Herring" <robh+dt@kernel.org>,
"Pengutronix Kernel Team" <kernel@pengutronix.de>,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 1/8] dt-bindings: display: mxsfb: Convert binding to YAML
Date: Mon, 17 Aug 2020 03:00:49 +0300 [thread overview]
Message-ID: <20200817000049.GB7729@pendragon.ideasonboard.com> (raw)
In-Reply-To: <20200816062242.GB1201814@ravnborg.org>
Hi Sam,
On Sun, Aug 16, 2020 at 08:22:42AM +0200, Sam Ravnborg wrote:
> Hi Laurent.
>
> Good to see one of the imx bindings migrating to yaml.
>
> On Thu, Aug 13, 2020 at 04:29:03AM +0300, Laurent Pinchart wrote:
> > Convert the mxsfb binding to YAML. The deprecated binding is dropped, as
> > neither the DT sources nor the driver support it anymore.
> >
> > The compatible strings are messy, and DT sources use different kinds of
> > combination of documented and undocumented values. Keep it simple for
> > now, and update the example to make it valid. Aligning the binding with
> > the existing DT sources will be performed separately.
> >
> > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
>
> Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
> But see below for a few nits
>
> > ---
> > .../devicetree/bindings/display/mxsfb.txt | 87 -------------
> > .../devicetree/bindings/display/mxsfb.yaml | 115 ++++++++++++++++++
> > MAINTAINERS | 2 +-
> > 3 files changed, 116 insertions(+), 88 deletions(-)
> > delete mode 100644 Documentation/devicetree/bindings/display/mxsfb.txt
> > create mode 100644 Documentation/devicetree/bindings/display/mxsfb.yaml
> >
> > diff --git a/Documentation/devicetree/bindings/display/mxsfb.txt b/Documentation/devicetree/bindings/display/mxsfb.txt
> > deleted file mode 100644
> > index c985871c46b3..000000000000
> > --- a/Documentation/devicetree/bindings/display/mxsfb.txt
> > +++ /dev/null
> > @@ -1,87 +0,0 @@
> > -* Freescale MXS LCD Interface (LCDIF)
> > -
> > -New bindings:
> > -=============
> > -Required properties:
> > -- compatible: Should be "fsl,imx23-lcdif" for i.MX23.
> > - Should be "fsl,imx28-lcdif" for i.MX28.
> > - Should be "fsl,imx6sx-lcdif" for i.MX6SX.
> > - Should be "fsl,imx8mq-lcdif" for i.MX8MQ.
> > -- reg: Address and length of the register set for LCDIF
> > -- interrupts: Should contain LCDIF interrupt
> > -- clocks: A list of phandle + clock-specifier pairs, one for each
> > - entry in 'clock-names'.
> > -- clock-names: A list of clock names. For MXSFB it should contain:
> > - - "pix" for the LCDIF block clock
> > - - (MX6SX-only) "axi", "disp_axi" for the bus interface clock
> > -
> > -Required sub-nodes:
> > - - port: The connection to an encoder chip.
> > -
> > -Example:
> > -
> > - lcdif1: display-controller@2220000 {
> > - compatible = "fsl,imx6sx-lcdif", "fsl,imx28-lcdif";
> > - reg = <0x02220000 0x4000>;
> > - interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
> > - clocks = <&clks IMX6SX_CLK_LCDIF1_PIX>,
> > - <&clks IMX6SX_CLK_LCDIF_APB>,
> > - <&clks IMX6SX_CLK_DISPLAY_AXI>;
> > - clock-names = "pix", "axi", "disp_axi";
> > -
> > - port {
> > - parallel_out: endpoint {
> > - remote-endpoint = <&panel_in_parallel>;
> > - };
> > - };
> > - };
> > -
> > -Deprecated bindings:
> > -====================
> > -Required properties:
> > -- compatible: Should be "fsl,imx23-lcdif" for i.MX23.
> > - Should be "fsl,imx28-lcdif" for i.MX28.
> > -- reg: Address and length of the register set for LCDIF
> > -- interrupts: Should contain LCDIF interrupts
> > -- display: phandle to display node (see below for details)
> > -
> > -* display node
> > -
> > -Required properties:
> > -- bits-per-pixel: <16> for RGB565, <32> for RGB888/666.
> > -- bus-width: number of data lines. Could be <8>, <16>, <18> or <24>.
> > -
> > -Required sub-node:
> > -- display-timings: Refer to binding doc display-timing.txt for details.
> > -
> > -Examples:
> > -
> > -lcdif@80030000 {
> > - compatible = "fsl,imx28-lcdif";
> > - reg = <0x80030000 2000>;
> > - interrupts = <38 86>;
> > -
> > - display: display {
> > - bits-per-pixel = <32>;
> > - bus-width = <24>;
> > -
> > - display-timings {
> > - native-mode = <&timing0>;
> > - timing0: timing0 {
> > - clock-frequency = <33500000>;
> > - hactive = <800>;
> > - vactive = <480>;
> > - hfront-porch = <164>;
> > - hback-porch = <89>;
> > - hsync-len = <10>;
> > - vback-porch = <23>;
> > - vfront-porch = <10>;
> > - vsync-len = <10>;
> > - hsync-active = <0>;
> > - vsync-active = <0>;
> > - de-active = <1>;
> > - pixelclk-active = <0>;
> > - };
> > - };
> > - };
> > -};
> > diff --git a/Documentation/devicetree/bindings/display/mxsfb.yaml b/Documentation/devicetree/bindings/display/mxsfb.yaml
> > new file mode 100644
> > index 000000000000..202381ec5bb7
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/display/mxsfb.yaml
> > @@ -0,0 +1,115 @@
> > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/display/mxsfb.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Freescale/NXP i.MX LCD Interface (LCDIF)
> > +
> > +maintainers:
> > + - Marek Vasut <marex@denx.de>
> > + - Stefan Agner <stefan@agner.ch>
> > +
> > +description: |
> > + (e)LCDIF display controller found in the Freescale/NXP i.MX SoCs.
> > +
> > +properties:
> > + compatible:
> > + enum:
> > + - fsl,imx23-lcdif
> > + - fsl,imx28-lcdif
> > + - fsl,imx6sx-lcdif
> > + - fsl,imx8mq-lcdif
> > +
> > + reg:
> > + maxItems: 1
> > +
> > + clocks:
> > + items:
> > + - description: Pixel clock
> > + - description: Bus clock
> > + - description: Display AXI clock
> > + minItems: 1
> > +
> > + clock-names:
> > + items:
> > + - const: "pix"
> > + - const: "axi"
> > + - const: "disp_axi"
> > + minItems: 1
> > +
> > + interrupts:
> > + maxItems: 1
> > +
> > + port:
> > + description: The LCDIF output port
> > + type: object
> > +
> > + properties:
> > + endpoint:
> > + type: object
> > +
> > + properties:
> > + remote-endpoint:
> > + $ref: /schemas/types.yaml#/definitions/phandle
> > +
> > + required:
> > + - remote-endpoint
> > +
> > + additionalProperties: false
> > +
> > + additionalProperties: false
> > +
> > +required:
> > + - compatible
> > + - reg
> > + - clocks
> > + - interrupts
> > + - port
> > +
> > +additionalProperties: false
> > +
> > +allOf:
> > + - if:
> > + properties:
> > + compatible:
> > + contains:
> > + const: fsl,imx6sx-lcdif
> > + then:
> > + properties:
> > + clocks:
> > + minItems: 2
> > + maxItems: 3
> > + clock-names:
> > + minItems: 2
> > + maxItems: 3
> > + required:
> > + - clock-names
> > + else:
> > + properties:
> > + clocks:
> > + minItems: 1
> > + clock-names:
> > + minItems: 1
>
> The else parts looks like it is not needed.
> The clock, clock-names properties has minItems: 1 already from above.
Conceptually you're right, this should be maxItems, not minItems.
However, the DT schema checker automatically adds a maxItems property
that equal minItems when only minItems is specified (and the other way
around as well). This is meant to allow shorter notations. I'm not
convinced it's a good idea, but that's the way it is today.
I'll change to maxItems as it's more explicit.
> > +
> > +examples:
> > + - |
> > + #include <dt-bindings/clock/imx6sx-clock.h>
> > + #include <dt-bindings/interrupt-controller/arm-gic.h>
> > +
> > + display-controller@2220000 {
> > + compatible = "fsl,imx6sx-lcdif";
> > + reg = <0x02220000 0x4000>;
> > + interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
> > + clocks = <&clks IMX6SX_CLK_LCDIF1_PIX>,
> > + <&clks IMX6SX_CLK_LCDIF_APB>,
> > + <&clks IMX6SX_CLK_DISPLAY_AXI>;
> > + clock-names = "pix", "axi", "disp_axi";
> > +
> > + port {
> > + endpoint {
> > + remote-endpoint = <&panel_in>;
> > + };
> > + };
> > + };
>
> empty line before "..." - at least most files have it
I'll add that.
> > +...
> > diff --git a/MAINTAINERS b/MAINTAINERS
> > index e3467e88714f..e3fac23383d2 100644
> > --- a/MAINTAINERS
> > +++ b/MAINTAINERS
> > @@ -11757,7 +11757,7 @@ M: Stefan Agner <stefan@agner.ch>
> > L: dri-devel@lists.freedesktop.org
> > S: Supported
> > T: git git://anongit.freedesktop.org/drm/drm-misc
> > -F: Documentation/devicetree/bindings/display/mxsfb.txt
> > +F: Documentation/devicetree/bindings/display/mxsfb.yaml
> > F: drivers/gpu/drm/mxsfb/
> >
> > MYLEX DAC960 PCI RAID Controller
--
Regards,
Laurent Pinchart
WARNING: multiple messages have this Message-ID (diff)
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: "Marek Vasut" <marex@denx.de>,
devicetree@vger.kernel.org, "Guido Günther" <agx@sigxcpu.org>,
dri-devel@lists.freedesktop.org,
"Rob Herring" <robh+dt@kernel.org>,
"Pengutronix Kernel Team" <kernel@pengutronix.de>,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 1/8] dt-bindings: display: mxsfb: Convert binding to YAML
Date: Mon, 17 Aug 2020 03:00:49 +0300 [thread overview]
Message-ID: <20200817000049.GB7729@pendragon.ideasonboard.com> (raw)
In-Reply-To: <20200816062242.GB1201814@ravnborg.org>
Hi Sam,
On Sun, Aug 16, 2020 at 08:22:42AM +0200, Sam Ravnborg wrote:
> Hi Laurent.
>
> Good to see one of the imx bindings migrating to yaml.
>
> On Thu, Aug 13, 2020 at 04:29:03AM +0300, Laurent Pinchart wrote:
> > Convert the mxsfb binding to YAML. The deprecated binding is dropped, as
> > neither the DT sources nor the driver support it anymore.
> >
> > The compatible strings are messy, and DT sources use different kinds of
> > combination of documented and undocumented values. Keep it simple for
> > now, and update the example to make it valid. Aligning the binding with
> > the existing DT sources will be performed separately.
> >
> > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
>
> Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
> But see below for a few nits
>
> > ---
> > .../devicetree/bindings/display/mxsfb.txt | 87 -------------
> > .../devicetree/bindings/display/mxsfb.yaml | 115 ++++++++++++++++++
> > MAINTAINERS | 2 +-
> > 3 files changed, 116 insertions(+), 88 deletions(-)
> > delete mode 100644 Documentation/devicetree/bindings/display/mxsfb.txt
> > create mode 100644 Documentation/devicetree/bindings/display/mxsfb.yaml
> >
> > diff --git a/Documentation/devicetree/bindings/display/mxsfb.txt b/Documentation/devicetree/bindings/display/mxsfb.txt
> > deleted file mode 100644
> > index c985871c46b3..000000000000
> > --- a/Documentation/devicetree/bindings/display/mxsfb.txt
> > +++ /dev/null
> > @@ -1,87 +0,0 @@
> > -* Freescale MXS LCD Interface (LCDIF)
> > -
> > -New bindings:
> > -=============
> > -Required properties:
> > -- compatible: Should be "fsl,imx23-lcdif" for i.MX23.
> > - Should be "fsl,imx28-lcdif" for i.MX28.
> > - Should be "fsl,imx6sx-lcdif" for i.MX6SX.
> > - Should be "fsl,imx8mq-lcdif" for i.MX8MQ.
> > -- reg: Address and length of the register set for LCDIF
> > -- interrupts: Should contain LCDIF interrupt
> > -- clocks: A list of phandle + clock-specifier pairs, one for each
> > - entry in 'clock-names'.
> > -- clock-names: A list of clock names. For MXSFB it should contain:
> > - - "pix" for the LCDIF block clock
> > - - (MX6SX-only) "axi", "disp_axi" for the bus interface clock
> > -
> > -Required sub-nodes:
> > - - port: The connection to an encoder chip.
> > -
> > -Example:
> > -
> > - lcdif1: display-controller@2220000 {
> > - compatible = "fsl,imx6sx-lcdif", "fsl,imx28-lcdif";
> > - reg = <0x02220000 0x4000>;
> > - interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
> > - clocks = <&clks IMX6SX_CLK_LCDIF1_PIX>,
> > - <&clks IMX6SX_CLK_LCDIF_APB>,
> > - <&clks IMX6SX_CLK_DISPLAY_AXI>;
> > - clock-names = "pix", "axi", "disp_axi";
> > -
> > - port {
> > - parallel_out: endpoint {
> > - remote-endpoint = <&panel_in_parallel>;
> > - };
> > - };
> > - };
> > -
> > -Deprecated bindings:
> > -====================
> > -Required properties:
> > -- compatible: Should be "fsl,imx23-lcdif" for i.MX23.
> > - Should be "fsl,imx28-lcdif" for i.MX28.
> > -- reg: Address and length of the register set for LCDIF
> > -- interrupts: Should contain LCDIF interrupts
> > -- display: phandle to display node (see below for details)
> > -
> > -* display node
> > -
> > -Required properties:
> > -- bits-per-pixel: <16> for RGB565, <32> for RGB888/666.
> > -- bus-width: number of data lines. Could be <8>, <16>, <18> or <24>.
> > -
> > -Required sub-node:
> > -- display-timings: Refer to binding doc display-timing.txt for details.
> > -
> > -Examples:
> > -
> > -lcdif@80030000 {
> > - compatible = "fsl,imx28-lcdif";
> > - reg = <0x80030000 2000>;
> > - interrupts = <38 86>;
> > -
> > - display: display {
> > - bits-per-pixel = <32>;
> > - bus-width = <24>;
> > -
> > - display-timings {
> > - native-mode = <&timing0>;
> > - timing0: timing0 {
> > - clock-frequency = <33500000>;
> > - hactive = <800>;
> > - vactive = <480>;
> > - hfront-porch = <164>;
> > - hback-porch = <89>;
> > - hsync-len = <10>;
> > - vback-porch = <23>;
> > - vfront-porch = <10>;
> > - vsync-len = <10>;
> > - hsync-active = <0>;
> > - vsync-active = <0>;
> > - de-active = <1>;
> > - pixelclk-active = <0>;
> > - };
> > - };
> > - };
> > -};
> > diff --git a/Documentation/devicetree/bindings/display/mxsfb.yaml b/Documentation/devicetree/bindings/display/mxsfb.yaml
> > new file mode 100644
> > index 000000000000..202381ec5bb7
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/display/mxsfb.yaml
> > @@ -0,0 +1,115 @@
> > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/display/mxsfb.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Freescale/NXP i.MX LCD Interface (LCDIF)
> > +
> > +maintainers:
> > + - Marek Vasut <marex@denx.de>
> > + - Stefan Agner <stefan@agner.ch>
> > +
> > +description: |
> > + (e)LCDIF display controller found in the Freescale/NXP i.MX SoCs.
> > +
> > +properties:
> > + compatible:
> > + enum:
> > + - fsl,imx23-lcdif
> > + - fsl,imx28-lcdif
> > + - fsl,imx6sx-lcdif
> > + - fsl,imx8mq-lcdif
> > +
> > + reg:
> > + maxItems: 1
> > +
> > + clocks:
> > + items:
> > + - description: Pixel clock
> > + - description: Bus clock
> > + - description: Display AXI clock
> > + minItems: 1
> > +
> > + clock-names:
> > + items:
> > + - const: "pix"
> > + - const: "axi"
> > + - const: "disp_axi"
> > + minItems: 1
> > +
> > + interrupts:
> > + maxItems: 1
> > +
> > + port:
> > + description: The LCDIF output port
> > + type: object
> > +
> > + properties:
> > + endpoint:
> > + type: object
> > +
> > + properties:
> > + remote-endpoint:
> > + $ref: /schemas/types.yaml#/definitions/phandle
> > +
> > + required:
> > + - remote-endpoint
> > +
> > + additionalProperties: false
> > +
> > + additionalProperties: false
> > +
> > +required:
> > + - compatible
> > + - reg
> > + - clocks
> > + - interrupts
> > + - port
> > +
> > +additionalProperties: false
> > +
> > +allOf:
> > + - if:
> > + properties:
> > + compatible:
> > + contains:
> > + const: fsl,imx6sx-lcdif
> > + then:
> > + properties:
> > + clocks:
> > + minItems: 2
> > + maxItems: 3
> > + clock-names:
> > + minItems: 2
> > + maxItems: 3
> > + required:
> > + - clock-names
> > + else:
> > + properties:
> > + clocks:
> > + minItems: 1
> > + clock-names:
> > + minItems: 1
>
> The else parts looks like it is not needed.
> The clock, clock-names properties has minItems: 1 already from above.
Conceptually you're right, this should be maxItems, not minItems.
However, the DT schema checker automatically adds a maxItems property
that equal minItems when only minItems is specified (and the other way
around as well). This is meant to allow shorter notations. I'm not
convinced it's a good idea, but that's the way it is today.
I'll change to maxItems as it's more explicit.
> > +
> > +examples:
> > + - |
> > + #include <dt-bindings/clock/imx6sx-clock.h>
> > + #include <dt-bindings/interrupt-controller/arm-gic.h>
> > +
> > + display-controller@2220000 {
> > + compatible = "fsl,imx6sx-lcdif";
> > + reg = <0x02220000 0x4000>;
> > + interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
> > + clocks = <&clks IMX6SX_CLK_LCDIF1_PIX>,
> > + <&clks IMX6SX_CLK_LCDIF_APB>,
> > + <&clks IMX6SX_CLK_DISPLAY_AXI>;
> > + clock-names = "pix", "axi", "disp_axi";
> > +
> > + port {
> > + endpoint {
> > + remote-endpoint = <&panel_in>;
> > + };
> > + };
> > + };
>
> empty line before "..." - at least most files have it
I'll add that.
> > +...
> > diff --git a/MAINTAINERS b/MAINTAINERS
> > index e3467e88714f..e3fac23383d2 100644
> > --- a/MAINTAINERS
> > +++ b/MAINTAINERS
> > @@ -11757,7 +11757,7 @@ M: Stefan Agner <stefan@agner.ch>
> > L: dri-devel@lists.freedesktop.org
> > S: Supported
> > T: git git://anongit.freedesktop.org/drm/drm-misc
> > -F: Documentation/devicetree/bindings/display/mxsfb.txt
> > +F: Documentation/devicetree/bindings/display/mxsfb.yaml
> > F: drivers/gpu/drm/mxsfb/
> >
> > MYLEX DAC960 PCI RAID Controller
--
Regards,
Laurent Pinchart
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2020-08-17 0:03 UTC|newest]
Thread overview: 93+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-13 1:29 [PATCH 0/8] drm: mxsfb: Allow overriding bus width Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` [PATCH 1/8] dt-bindings: display: mxsfb: Convert binding to YAML Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-16 6:22 ` Sam Ravnborg
2020-08-16 6:22 ` Sam Ravnborg
2020-08-16 6:22 ` Sam Ravnborg
2020-08-17 0:00 ` Laurent Pinchart [this message]
2020-08-17 0:00 ` Laurent Pinchart
2020-08-17 0:00 ` Laurent Pinchart
2020-08-24 23:59 ` Rob Herring
2020-08-24 23:59 ` Rob Herring
2020-08-24 23:59 ` Rob Herring
2020-08-13 1:29 ` [PATCH 2/8] dt-bindings: display: mxsfb: Add and fix compatible strings Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-16 6:39 ` Sam Ravnborg
2020-08-16 6:39 ` Sam Ravnborg
2020-08-16 6:39 ` Sam Ravnborg
2020-08-17 0:04 ` Laurent Pinchart
2020-08-17 0:04 ` Laurent Pinchart
2020-08-17 0:04 ` Laurent Pinchart
2020-08-24 23:57 ` Rob Herring
2020-08-24 23:57 ` Rob Herring
2020-08-24 23:57 ` Rob Herring
2020-08-21 14:53 ` Stefan Agner
2020-08-21 14:53 ` Stefan Agner
2020-08-21 14:53 ` Stefan Agner
2020-08-23 23:26 ` Laurent Pinchart
2020-08-23 23:26 ` Laurent Pinchart
2020-08-23 23:26 ` Laurent Pinchart
2020-08-24 14:19 ` Stefan Agner
2020-08-24 14:19 ` Stefan Agner
2020-08-24 14:19 ` Stefan Agner
2020-10-07 1:12 ` Laurent Pinchart
2020-10-07 1:12 ` Laurent Pinchart
2020-10-07 1:12 ` Laurent Pinchart
2020-08-13 1:29 ` [PATCH 3/8] dt-bindings: display: mxsfb: Add a bus-width endpoint property Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-15 21:28 ` Guido Günther
2020-08-15 21:28 ` Guido Günther
2020-08-15 21:28 ` Guido Günther
2020-08-17 0:09 ` Laurent Pinchart
2020-08-17 0:09 ` Laurent Pinchart
2020-08-17 0:09 ` Laurent Pinchart
2020-08-16 7:25 ` Sam Ravnborg
2020-08-16 7:25 ` Sam Ravnborg
2020-08-16 7:25 ` Sam Ravnborg
2020-08-17 0:17 ` Laurent Pinchart
2020-08-17 0:17 ` Laurent Pinchart
2020-08-17 0:17 ` Laurent Pinchart
2020-08-13 1:29 ` [PATCH 4/8] dt-bindings: display: mxsfb: Rename to fsl,lcdif.yaml Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-16 7:27 ` [PATCH 4/8] dt-bindings: display: mxsfb: Rename to fsl, lcdif.yaml Sam Ravnborg
2020-08-16 7:27 ` Sam Ravnborg
2020-08-16 7:27 ` [PATCH 4/8] dt-bindings: display: mxsfb: Rename to fsl,lcdif.yaml Sam Ravnborg
2020-08-21 14:55 ` [PATCH 4/8] dt-bindings: display: mxsfb: Rename to fsl, lcdif.yaml Stefan Agner
2020-08-21 14:55 ` Stefan Agner
2020-08-21 14:55 ` [PATCH 4/8] dt-bindings: display: mxsfb: Rename to fsl,lcdif.yaml Stefan Agner
2020-08-23 23:27 ` [PATCH 4/8] dt-bindings: display: mxsfb: Rename to fsl, lcdif.yaml Laurent Pinchart
2020-08-23 23:27 ` Laurent Pinchart
2020-08-23 23:27 ` [PATCH 4/8] dt-bindings: display: mxsfb: Rename to fsl,lcdif.yaml Laurent Pinchart
2020-08-13 1:29 ` [PATCH 5/8] ARM: dts: imx: Fix LCDIF compatible strings Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-16 7:28 ` Sam Ravnborg
2020-08-16 7:28 ` Sam Ravnborg
2020-08-16 7:28 ` Sam Ravnborg
2020-08-13 1:29 ` [PATCH 6/8] arm64: dts: imx8mq: " Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-16 7:28 ` Sam Ravnborg
2020-08-16 7:28 ` Sam Ravnborg
2020-08-16 7:28 ` Sam Ravnborg
2020-08-13 1:29 ` [PATCH 7/8] ARM: dts: imx: Remove unneeded LCDIF disp_axi clock Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-16 7:28 ` Sam Ravnborg
2020-08-16 7:28 ` Sam Ravnborg
2020-08-16 7:28 ` Sam Ravnborg
2020-08-13 1:29 ` [PATCH 8/8] drm: mxsfb: Add support for the bus-width DT property Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-13 1:29 ` Laurent Pinchart
2020-08-16 7:46 ` Sam Ravnborg
2020-08-16 7:46 ` Sam Ravnborg
2020-08-16 7:46 ` Sam Ravnborg
2020-08-17 0:29 ` Laurent Pinchart
2020-08-17 0:29 ` Laurent Pinchart
2020-08-17 0:29 ` Laurent Pinchart
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200817000049.GB7729@pendragon.ideasonboard.com \
--to=laurent.pinchart@ideasonboard.com \
--cc=agx@sigxcpu.org \
--cc=devicetree@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=kernel@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=marex@denx.de \
--cc=robh+dt@kernel.org \
--cc=sam@ravnborg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.