dt-bindings: display: imx: Document fsl,pcr
Subsystems (5)
Fabio Estevam
reviewerPATCH v2 1/1 dt-bindings: display: imx: Document fsl,pcr
Some i.MX25 and i.MX27 devicetree display nodes contain fsl,pcr, but the property has no schema type. As a result, dt-core.yaml reports its raw bytes as an invalid property:
imx27-phytec-phycard-s-rdk.dtb: display: fsl,pcr:
b'\xf0\xc8\x80\x80' is not of type 'object', 'integer', 'array', 'boolean', 'null'
Document fsl,pcr as a uint32. The property belongs to the display node referenced by the display phandle and is not valid on the LCD controller node.
---
Changes since v1:
- Explicitly forbid fsl,pcr on the controller through allOf, addressing the Sashiko review, while retaining its uint32 type for decoding the property in legacy display nodes.
.../devicetree/bindings/display/imx/fsl,imx-lcdc.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+)
Documentation/devicetree/bindings/display/imx/fsl,imx-lcdc.yaml +10 -0
@@ -65,7 +65,17 @@ properties: description: LCDC Sharp Configuration Register value. + fsl,pcr: + $ref: /schemas/types.yaml#/definitions/uint32 + description: + LCDC Panel Configuration Register value used in the display node + referenced by the display property. + allOf: + # Define the type above for decoding, but forbid it on the controller. + - properties: + fsl,pcr: false + - if: properties: compatible:
Rob Herring
maintainerQuoted 31 lines · Fabio Estevam
Some i.MX25 and i.MX27 devicetree display nodes contain fsl,pcr, but the property has no schema type. As a result,
dt-core.yamlreports its raw bytes as an invalid property:imx27-phytec-phycard-s-rdk.dtb: display: fsl,pcr:
b'\xf0\xc8\x80\x80' is not of type 'object', 'integer', 'array', 'boolean', 'null'Document fsl,pcr as a uint32. The property belongs to the display node referenced by the display phandle and is not valid on the LCD controller node.
Signed-off-by Fabio Estevam <[email protected]>---
Changes since v1:
- Explicitly forbid fsl,pcr on the controller through allOf, addressing the Sashiko review, while retaining its uint32 type for decoding the property in legacy display nodes..../devicetree/bindings/display/imx/fsl,imx-lcdc.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+)Documentation/devicetree/bindings/display/imx/fsl,imx-lcdc.yaml +0
-0@@ -65,7 +65,17 @@ properties: description: LCDC Sharp Configuration Register value.
Documentation/devicetree/bindings/display/imx/fsl,imx-lcdc.yaml properties: · line 77
Quoted 10 lines
Documentation/devicetree/bindings/display/imx/fsl,imx-lcdc.yaml +9
-0+ fsl,pcr: + $ref: /schemas/types.yaml#/definitions/uint32 + description: + LCDC Panel Configuration Register value used in the display node + referenced by the display property. + allOf: + # Define the type above for decoding, but forbid it on the controller. + - properties: + fsl,pcr: false
That does fix the warning, but still leaves display nodes unvalidated. This needs to go in a new schema. Since there's no compatible on these nodes, we need something like this to apply the schema:
select:
required:
- fsl,pcr
Then the schema is this property, model, bits-per-pixel and a $ref to panel-common.yaml.
Rob