Message ID | 20220710090040.35193-12-dmitry.baryshkov@linaro.org (mailing list archive) |
---|---|
State | Not Applicable |
Headers | show |
Series | dt-bindings: display/msm: rework MDSS and DPU bindings | expand |
On Sun, Jul 10, 2022 at 12:00:40PM +0300, Dmitry Baryshkov wrote: > Move properties common to all DPU DT nodes to the dpu-common.yaml. > > Note, this removes description of individual DPU port@ nodes. However > such definitions add no additional value. The reg values do not > correspond to hardware INTF indices. The driver discovers and binds > these ports not paying any care for the order of these items. Thus just > leave the reference to graph.yaml#/properties/ports and the description. > > Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> > --- > .../bindings/display/msm/dpu-common.yaml | 42 ++++++++++++++++++ > .../bindings/display/msm/dpu-msm8998.yaml | 43 ++----------------- > .../bindings/display/msm/dpu-qcm2290.yaml | 39 ++--------------- > .../bindings/display/msm/dpu-sc7180.yaml | 43 ++----------------- > .../bindings/display/msm/dpu-sc7280.yaml | 43 ++----------------- > .../bindings/display/msm/dpu-sdm845.yaml | 43 ++----------------- > 6 files changed, 62 insertions(+), 191 deletions(-) > create mode 100644 Documentation/devicetree/bindings/display/msm/dpu-common.yaml > > diff --git a/Documentation/devicetree/bindings/display/msm/dpu-common.yaml b/Documentation/devicetree/bindings/display/msm/dpu-common.yaml > new file mode 100644 > index 000000000000..14eda883e149 > --- /dev/null > +++ b/Documentation/devicetree/bindings/display/msm/dpu-common.yaml > @@ -0,0 +1,42 @@ > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/display/msm/dpu-common.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Qualcomm Display DPU dt properties (common properties) > + > +maintainers: > + - Dmitry Baryshkov <dmitry.baryshkov@linaro.org> > + - Krishna Manikandan <quic_mkrishn@quicinc.com> > + - Rob Clark <robdclark@gmail.com> > + > +description: | > + Common properties for QCom DPU display controller. > + > +properties: > + interrupts: > + maxItems: 1 > + > + power-domains: > + maxItems: 1 > + > + operating-points-v2: true > + > + ports: > + $ref: /schemas/graph.yaml#/properties/ports > + description: | > + Contains the list of output ports from DPU device. These ports > + connect to interfaces that are external to the DPU hardware, > + such as DSI, DP etc. From the last version: > In case of MDSS all ports are output, they are connected to the external > interfaces (DSI, DP, HDMI, etc). The driver uses them to bind available > interfaces (using components framework). The reg property of the port is > completely ignored. It doesn't matter what the driver does or doesn't do. Without describing port nodes at all, you are not validating what port nodes can contain. Just try adding any property under a port node. You need at least: '^port@[0-N]$': $ref: graph.yaml#/properties/port where N is the max number of ports. Rob
On 18/07/2022 20:50, Rob Herring wrote: > On Sun, Jul 10, 2022 at 12:00:40PM +0300, Dmitry Baryshkov wrote: >> Move properties common to all DPU DT nodes to the dpu-common.yaml. >> >> Note, this removes description of individual DPU port@ nodes. However >> such definitions add no additional value. The reg values do not >> correspond to hardware INTF indices. The driver discovers and binds >> these ports not paying any care for the order of these items. Thus just >> leave the reference to graph.yaml#/properties/ports and the description. >> >> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> >> --- >> .../bindings/display/msm/dpu-common.yaml | 42 ++++++++++++++++++ >> .../bindings/display/msm/dpu-msm8998.yaml | 43 ++----------------- >> .../bindings/display/msm/dpu-qcm2290.yaml | 39 ++--------------- >> .../bindings/display/msm/dpu-sc7180.yaml | 43 ++----------------- >> .../bindings/display/msm/dpu-sc7280.yaml | 43 ++----------------- >> .../bindings/display/msm/dpu-sdm845.yaml | 43 ++----------------- >> 6 files changed, 62 insertions(+), 191 deletions(-) >> create mode 100644 Documentation/devicetree/bindings/display/msm/dpu-common.yaml >> >> diff --git a/Documentation/devicetree/bindings/display/msm/dpu-common.yaml b/Documentation/devicetree/bindings/display/msm/dpu-common.yaml >> new file mode 100644 >> index 000000000000..14eda883e149 >> --- /dev/null >> +++ b/Documentation/devicetree/bindings/display/msm/dpu-common.yaml >> @@ -0,0 +1,42 @@ >> +%YAML 1.2 >> +--- >> +$id: http://devicetree.org/schemas/display/msm/dpu-common.yaml# >> +$schema: http://devicetree.org/meta-schemas/core.yaml# >> + >> +title: Qualcomm Display DPU dt properties (common properties) >> + >> +maintainers: >> + - Dmitry Baryshkov <dmitry.baryshkov@linaro.org> >> + - Krishna Manikandan <quic_mkrishn@quicinc.com> >> + - Rob Clark <robdclark@gmail.com> >> + >> +description: | >> + Common properties for QCom DPU display controller. >> + >> +properties: >> + interrupts: >> + maxItems: 1 >> + >> + power-domains: >> + maxItems: 1 >> + >> + operating-points-v2: true >> + >> + ports: >> + $ref: /schemas/graph.yaml#/properties/ports >> + description: | >> + Contains the list of output ports from DPU device. These ports >> + connect to interfaces that are external to the DPU hardware, >> + such as DSI, DP etc. > > From the last version: > >> In case of MDSS all ports are output, they are connected to the external >> interfaces (DSI, DP, HDMI, etc). The driver uses them to bind available >> interfaces (using components framework). The reg property of the port is >> completely ignored. > > It doesn't matter what the driver does or doesn't do. Without > describing port nodes at all, you are not validating what port nodes > can contain. Just try adding any property under a port node. You need at > least: > > '^port@[0-N]$': > $ref: graph.yaml#/properties/port Hmm, the graph.yaml already restricts the ports node to the ports@[0-9a-f]+$ + #address-cells/#size-cells. I don't think we have to add any additional restrictions/entries here. Do we? > > where N is the max number of ports. > > Rob
diff --git a/Documentation/devicetree/bindings/display/msm/dpu-common.yaml b/Documentation/devicetree/bindings/display/msm/dpu-common.yaml new file mode 100644 index 000000000000..14eda883e149 --- /dev/null +++ b/Documentation/devicetree/bindings/display/msm/dpu-common.yaml @@ -0,0 +1,42 @@ +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/display/msm/dpu-common.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm Display DPU dt properties (common properties) + +maintainers: + - Dmitry Baryshkov <dmitry.baryshkov@linaro.org> + - Krishna Manikandan <quic_mkrishn@quicinc.com> + - Rob Clark <robdclark@gmail.com> + +description: | + Common properties for QCom DPU display controller. + +properties: + interrupts: + maxItems: 1 + + power-domains: + maxItems: 1 + + operating-points-v2: true + + ports: + $ref: /schemas/graph.yaml#/properties/ports + description: | + Contains the list of output ports from DPU device. These ports + connect to interfaces that are external to the DPU hardware, + such as DSI, DP etc. + +required: + - compatible + - reg + - reg-names + - clocks + - interrupts + - power-domains + - operating-points-v2 + - ports + +additionalProperties: true diff --git a/Documentation/devicetree/bindings/display/msm/dpu-msm8998.yaml b/Documentation/devicetree/bindings/display/msm/dpu-msm8998.yaml index 5caf46a1dd88..158bd93a157f 100644 --- a/Documentation/devicetree/bindings/display/msm/dpu-msm8998.yaml +++ b/Documentation/devicetree/bindings/display/msm/dpu-msm8998.yaml @@ -47,45 +47,10 @@ properties: - const: core - const: vsync - interrupts: - maxItems: 1 - - power-domains: - maxItems: 1 - - operating-points-v2: true - ports: - $ref: /schemas/graph.yaml#/properties/ports - description: | - Contains the list of output ports from DPU device. These ports - connect to interfaces that are external to the DPU hardware, - such as DSI, DP etc. Each output port contains an endpoint that - describes how it is connected to an external interface. - - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF1 (DSI1) - - port@1: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF2 (DSI2) - - required: - - port@0 - - port@1 - -required: - - compatible - - reg - - reg-names - - clocks - - interrupts - - power-domains - - operating-points-v2 - - ports - -additionalProperties: false +allOf: + - $ref: "/schemas/display/msm/dpu-common.yaml#" + +unevaluatedProperties: false examples: - | diff --git a/Documentation/devicetree/bindings/display/msm/dpu-qcm2290.yaml b/Documentation/devicetree/bindings/display/msm/dpu-qcm2290.yaml index 8027319b1aad..0364261bf3d2 100644 --- a/Documentation/devicetree/bindings/display/msm/dpu-qcm2290.yaml +++ b/Documentation/devicetree/bindings/display/msm/dpu-qcm2290.yaml @@ -43,41 +43,10 @@ properties: - const: lut - const: vsync - interrupts: - maxItems: 1 - - power-domains: - maxItems: 1 - - operating-points-v2: true - - ports: - $ref: /schemas/graph.yaml#/properties/ports - description: | - Contains the list of output ports from DPU device. These ports - connect to interfaces that are external to the DPU hardware, - such as DSI. Each output port contains an endpoint that - describes how it is connected to an external interface. - - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF1 (DSI1) - - required: - - port@0 - -required: - - compatible - - reg - - reg-names - - clocks - - interrupts - - power-domains - - operating-points-v2 - - ports - -additionalProperties: false +allOf: + - $ref: "/schemas/display/msm/dpu-common.yaml#" + +unevaluatedProperties: false examples: - | diff --git a/Documentation/devicetree/bindings/display/msm/dpu-sc7180.yaml b/Documentation/devicetree/bindings/display/msm/dpu-sc7180.yaml index 9d4ec0b60c25..5df1f2d987c9 100644 --- a/Documentation/devicetree/bindings/display/msm/dpu-sc7180.yaml +++ b/Documentation/devicetree/bindings/display/msm/dpu-sc7180.yaml @@ -45,45 +45,10 @@ properties: - const: core - const: vsync - interrupts: - maxItems: 1 - - power-domains: - maxItems: 1 - - operating-points-v2: true - - ports: - $ref: /schemas/graph.yaml#/properties/ports - description: | - Contains the list of output ports from DPU device. These ports - connect to interfaces that are external to the DPU hardware, - such as DSI, DP etc. Each output port contains an endpoint that - describes how it is connected to an external interface. - - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF1 (DSI1) - - port@2: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF0 (DP) - - required: - - port@0 - -required: - - compatible - - reg - - reg-names - - clocks - - interrupts - - power-domains - - operating-points-v2 - - ports - -additionalProperties: false +allOf: + - $ref: "/schemas/display/msm/dpu-common.yaml#" + +unevaluatedProperties: false examples: - | diff --git a/Documentation/devicetree/bindings/display/msm/dpu-sc7280.yaml b/Documentation/devicetree/bindings/display/msm/dpu-sc7280.yaml index 349a454099ad..c822da588de0 100644 --- a/Documentation/devicetree/bindings/display/msm/dpu-sc7280.yaml +++ b/Documentation/devicetree/bindings/display/msm/dpu-sc7280.yaml @@ -44,45 +44,10 @@ properties: - const: core - const: vsync - interrupts: - maxItems: 1 - - power-domains: - maxItems: 1 - - operating-points-v2: true - - ports: - $ref: /schemas/graph.yaml#/properties/ports - description: | - Contains the list of output ports from DPU device. These ports - connect to interfaces that are external to the DPU hardware, - such as DSI, DP etc. Each output port contains an endpoint that - describes how it is connected to an external interface. - - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF1 (DSI) - - port@1: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF5 (EDP) - - required: - - port@0 - -required: - - compatible - - reg - - reg-names - - clocks - - interrupts - - power-domains - - operating-points-v2 - - ports - -additionalProperties: false +allOf: + - $ref: "/schemas/display/msm/dpu-common.yaml#" + +unevaluatedProperties: false examples: - | diff --git a/Documentation/devicetree/bindings/display/msm/dpu-sdm845.yaml b/Documentation/devicetree/bindings/display/msm/dpu-sdm845.yaml index 42ff85e80f45..218c9d0f3fed 100644 --- a/Documentation/devicetree/bindings/display/msm/dpu-sdm845.yaml +++ b/Documentation/devicetree/bindings/display/msm/dpu-sdm845.yaml @@ -43,45 +43,10 @@ properties: - const: core - const: vsync - interrupts: - maxItems: 1 - - power-domains: - maxItems: 1 - - operating-points-v2: true - ports: - $ref: /schemas/graph.yaml#/properties/ports - description: | - Contains the list of output ports from DPU device. These ports - connect to interfaces that are external to the DPU hardware, - such as DSI, DP etc. Each output port contains an endpoint that - describes how it is connected to an external interface. - - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF1 (DSI1) - - port@1: - $ref: /schemas/graph.yaml#/properties/port - description: DPU_INTF2 (DSI2) - - required: - - port@0 - - port@1 - -required: - - compatible - - reg - - reg-names - - clocks - - interrupts - - power-domains - - operating-points-v2 - - ports - -additionalProperties: false +allOf: + - $ref: "/schemas/display/msm/dpu-common.yaml#" + +unevaluatedProperties: false examples: - |
Move properties common to all DPU DT nodes to the dpu-common.yaml. Note, this removes description of individual DPU port@ nodes. However such definitions add no additional value. The reg values do not correspond to hardware INTF indices. The driver discovers and binds these ports not paying any care for the order of these items. Thus just leave the reference to graph.yaml#/properties/ports and the description. Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> --- .../bindings/display/msm/dpu-common.yaml | 42 ++++++++++++++++++ .../bindings/display/msm/dpu-msm8998.yaml | 43 ++----------------- .../bindings/display/msm/dpu-qcm2290.yaml | 39 ++--------------- .../bindings/display/msm/dpu-sc7180.yaml | 43 ++----------------- .../bindings/display/msm/dpu-sc7280.yaml | 43 ++----------------- .../bindings/display/msm/dpu-sdm845.yaml | 43 ++----------------- 6 files changed, 62 insertions(+), 191 deletions(-) create mode 100644 Documentation/devicetree/bindings/display/msm/dpu-common.yaml