Skip to contentSkip to conversation

MediaTek MT8195 display binding

PATCH Applied Rex-BC Chen 6 participants 21 messages Apr 19, 2022 – Apr 27, 2022

Subsystems (6)

v1 of 5 Applied Latest is v5 →

lore
Share & tools
lore
#0 lore raw

cover MediaTek MT8195 display binding

Add this series to present MediaTek display binding for MT8195. The reason I send this series is Jason and Nancy's binding patches are never received by devicetree mail server.
Therefore, I help them to resend binding patches.

All of these patches are reviewed in other series:
[1]: message id: [email protected] [2]: message id: [email protected]

This series depends on Yong's MT8195 IOMMU series:
[3]: message id: [email protected] Without this patch, some patches of this series will build failed.

Nancy.Lin (3):
dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195
dt-bindings: reset: mt8195: add vdosys1 reset control bit
dt-bindings: mediatek: add ethdr definition for mt8195

jason-jh.lin (2):
dt-bindings: arm: mediatek: mmsys: add power and gce properties
dt-bindings: arm: mediatek: mmsys: add mt8195 SoC binding

 .../bindings/arm/mediatek/mediatek,mmsys.yaml |  32 ++++
 .../display/mediatek/mediatek,ethdr.yaml      | 158 ++++++++++++++++++
 .../display/mediatek/mediatek,mdp-rdma.yaml   |  86 ++++++++++
 include/dt-bindings/reset/mt8195-resets.h     |  12 ++
 4 files changed, 288 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml
 create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml
Signature · 7 lines
2.18.0


_______________________________________________
Linux-mediatek mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-mediatek
#1 lore raw

PATCH 1/5 dt-bindings: arm: mediatek: mmsys: add power and gce properties

From: "jason-jh.lin" <[email protected]>

Power:
1. Add description for power-domains property.

GCE:
1. Add description for mboxes property.
2. Add description for mediatek,gce-client-reg property.

---
 .../bindings/arm/mediatek/mediatek,mmsys.yaml | 31 +++++++++++++++++++
 1 file changed, 31 insertions(+)
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +31 -0
index b31d90dc9eb4..6c2c3edcd443 100644
@@ -41,6 +41,30 @@ properties:
   reg:
     maxItems: 1
 
+  power-domains:
+    description:
+      A phandle and PM domain specifier as defined by bindings
+      of the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml for details.
+
+  mboxes:
+    description:
+      Using mailbox to communicate with GCE, it should have this
+      property and list of phandle, mailbox specifiers. See
+      Documentation/devicetree/bindings/mailbox/mtk-gce.txt for details.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+
+  mediatek,gce-client-reg:
+    description:
+      The register of client driver can be configured by gce with 4 arguments
+      defined in this property, such as phandle of gce, subsys id,
+      register offset and size.
+      Each subsys id is mapping to a base address of display function blocks
+      register which is defined in the gce header
+      include/dt-bindings/gce/<chip>-gce.h.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
+
   "#clock-cells":
     const: 1
 
@@ -56,9 +80,16 @@ additionalProperties: false
 
 examples:
   - |
+    #include <dt-bindings/power/mt8173-power.h>
+    #include <dt-bindings/gce/mt8173-gce.h>
+
     mmsys: syscon@14000000 {
         compatible = "mediatek,mt8173-mmsys", "syscon";
         reg = <0x14000000 0x1000>;
+        power-domains = <&spm MT8173_POWER_DOMAIN_MM>;
         #clock-cells = <1>;
         #reset-cells = <1>;
+        mboxes = <&gce 0 CMDQ_THR_PRIO_HIGHEST>,
+                 <&gce 1 CMDQ_THR_PRIO_HIGHEST>;
+        mediatek,gce-client-reg = <&gce SUBSYS_1400XXXX 0 0x1000>;
     };
Signature · 1 line
2.18.0
maintainer Applied
#2 lore raw

Re: [PATCH 1/5] dt-bindings: arm: mediatek: mmsys: add power and gce properties

Quoted 5 lines · Rex-BC Chen

From: "jason-jh.lin" <[email protected]>

Power:
1. Add description for power-domains property.

Quoted 7 lines

GCE:
1. Add description for mboxes property.
2. Add description for mediatek,gce-client-reg property.

Applied, thanks.

Matthias

Quoted 56 lines
---
  .../bindings/arm/mediatek/mediatek,mmsys.yaml | 31 +++++++++++++++++++
  1 file changed, 31 insertions(+)
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +31 -0
index b31d90dc9eb4..6c2c3edcd443 100644
@@ -41,6 +41,30 @@ properties:
    reg:
      maxItems: 1
 
+  power-domains:
+    description:
+      A phandle and PM domain specifier as defined by bindings
+      of the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml for details.
+
+  mboxes:
+    description:
+      Using mailbox to communicate with GCE, it should have this
+      property and list of phandle, mailbox specifiers. See
+      Documentation/devicetree/bindings/mailbox/mtk-gce.txt for details.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+
+  mediatek,gce-client-reg:
+    description:
+      The register of client driver can be configured by gce with 4 arguments
+      defined in this property, such as phandle of gce, subsys id,
+      register offset and size.
+      Each subsys id is mapping to a base address of display function blocks
+      register which is defined in the gce header
+      include/dt-bindings/gce/<chip>-gce.h.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
+
    "#clock-cells":
      const: 1
 
@@ -56,9 +80,16 @@ additionalProperties: false
 
  examples:
    - |
+    #include <dt-bindings/power/mt8173-power.h>
+    #include <dt-bindings/gce/mt8173-gce.h>
+
      mmsys: syscon@14000000 {
          compatible = "mediatek,mt8173-mmsys", "syscon";
          reg = <0x14000000 0x1000>;
+        power-domains = <&spm MT8173_POWER_DOMAIN_MM>;
          #clock-cells = <1>;
          #reset-cells = <1>;
+        mboxes = <&gce 0 CMDQ_THR_PRIO_HIGHEST>,
+                 <&gce 1 CMDQ_THR_PRIO_HIGHEST>;
+        mediatek,gce-client-reg = <&gce SUBSYS_1400XXXX 0 0x1000>;
      };
maintainer
#3 lore raw

Re: [PATCH 1/5] dt-bindings: arm: mediatek: mmsys: add power and gce properties

In reply to Rex-BC Chen
Quoted 21 lines · Rex-BC Chen

From: "jason-jh.lin" <[email protected]>

Power:
1. Add description for power-domains property.

GCE:
1. Add description for mboxes property.
2. Add description for mediatek,gce-client-reg property.

---
 .../bindings/arm/mediatek/mediatek,mmsys.yaml | 31 +++++++++++++++++++
 1 file changed, 31 insertions(+)
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +0 -0
index b31d90dc9eb4..6c2c3edcd443 100644

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 44

Quoted 4 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +1 -0
@@ -41,6 +41,30 @@ properties:
   reg:
     maxItems: 1
 
+  power-domains:

How many and what are they.

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 48

Quoted 4 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +4 -0
+    description:
+      A phandle and PM domain specifier as defined by bindings
+      of the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml for details.

Drop. Don't need generic descriptions of common properties.

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 50

Quoted 2 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +2 -0
+
+  mboxes:

How many?

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 52

Quoted 2 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +2 -0
+    description:
+      Using mailbox to communicate with GCE, it should have this

If using?

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 54

Quoted 2 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +2 -0
+      property and list of phandle, mailbox specifiers. See
+      Documentation/devicetree/bindings/mailbox/mtk-gce.txt for details.

Drop

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 55

Quoted 1 line
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +1 -0
+    $ref: /schemas/types.yaml#/definitions/phandle-array

Already has a type.

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 66

Quoted 11 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +11 -0
+
+  mediatek,gce-client-reg:
+    description:
+      The register of client driver can be configured by gce with 4 arguments
+      defined in this property, such as phandle of gce, subsys id,
+      register offset and size.
+      Each subsys id is mapping to a base address of display function blocks
+      register which is defined in the gce header
+      include/dt-bindings/gce/<chip>-gce.h.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1

This needs to define exact sizes.

items:
- items:
- description: phandle to GCE
- description: subsy id
- description: register offset
- description: register size

Quoted 25 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +8 -0
+
   "#clock-cells":
     const: 1
 
@@ -56,9 +80,16 @@ additionalProperties: false
 
 examples:
   - |
+    #include <dt-bindings/power/mt8173-power.h>
+    #include <dt-bindings/gce/mt8173-gce.h>
+
     mmsys: syscon@14000000 {
         compatible = "mediatek,mt8173-mmsys", "syscon";
         reg = <0x14000000 0x1000>;
+        power-domains = <&spm MT8173_POWER_DOMAIN_MM>;
         #clock-cells = <1>;
         #reset-cells = <1>;
+        mboxes = <&gce 0 CMDQ_THR_PRIO_HIGHEST>,
+                 <&gce 1 CMDQ_THR_PRIO_HIGHEST>;
+        mediatek,gce-client-reg = <&gce SUBSYS_1400XXXX 0 0x1000>;
     };
Signature · 1 line
2.18.0
#4 lore raw

Re: [PATCH 1/5] dt-bindings: arm: mediatek: mmsys: add power and gce properties

Hi Rob,

Thanks for the reviews.
Since this patch has already applied in:

https://git.kernel.org/pub/scm/linux/kernel/git/matthias.bgg/linux.git/commit/?h=v5.18-next/soc&id=1da90b8a7bae09358569dba26e784d1f471b4aa0

I'll send a fixup-patch for your commnet.

Quoted 35 lines · Rob Herring
Quoted 34 lines · Rex-BC Chen

From: "jason-jh.lin" <[email protected]>

Power:
1. Add description for power-domains property.

GCE:
1. Add description for mboxes property.
2. Add description for mediatek,gce-client-reg property.

Reviewed-by AngeloGioacchino Del Regno <

[email protected]>

---
 .../bindings/arm/mediatek/mediatek,mmsys.yaml | 31
+++++++++++++++++++
 1 file changed, 31 insertions(+)

diff --git a/Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yam l b/Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yam l
index b31d90dc9eb4..6c2c3edcd443 100644
---
a/Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yam l
+++
b/Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yam l

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +0 -0
@@ -41,6 +41,30 @@ properties:
   reg:
     maxItems: 1
 
Quoted 4 lines

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 44

Quoted 1 line
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +1 -0
+  power-domains:

How many and what are they.

maxItems: 1
description:
Each mmsys belongs to a power-domains, so we can add the power- domains property to make it clearer, and also bind to the power controller.

Quoted 8 lines
Quoted 5 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +4 -0
+    description:
+      A phandle and PM domain specifier as defined by bindings
+      of the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml

for details.

Drop. Don't need generic descriptions of common properties.

OK, I'll drop this.

Quoted 5 lines

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 50

Quoted 2 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +2 -0
+
+  mboxes:

How many?

minItems: 1

Quoted 5 lines

Review

Quoted 2 lines
(quoted diff) +2 -0
+    description:
+      Using mailbox to communicate with GCE, it should have this

If using?

description:
If using mailbox to communicate with GCE, it should have this property. GCE will help configure the hardware settings for the current mmsys data pipeline.

Quoted 6 lines
Quoted 3 lines
(quoted diff) +2 -0
+      property and list of phandle, mailbox specifiers. See
+      Documentation/devicetree/bindings/mailbox/mtk-gce.txt for

details.

Drop

OK, I'll drop this.

Quoted 4 lines
Quoted 1 line

+ $ref: /schemas/types.yaml#/definitions/phandle-array

Already has a type.

OK, I'll drop this.

Quoted 14 lines

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml properties: · line 66

Quoted 13 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +4 -0
+
+  mediatek,gce-client-reg:
+    description:
+      The register of client driver can be configured by gce with

4 arguments

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +3 -0
+      defined in this property, such as phandle of gce, subsys id,
+      register offset and size.
+      Each subsys id is mapping to a base address of display

function blocks

Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +4 -0
+      register which is defined in the gce header
+      include/dt-bindings/gce/<chip>-gce.h.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
Quoted 9 lines

This needs to define exact sizes.

items:
- items:
- description: phandle to GCE
- description: subsy id
- description: register offset
- description: register size

OK, I'll fix it like this:

mediatek,gce-client-reg:
minItems: 1
items:
- items:
- description: phandle to GCE
- description: subsys id
- description: register offset
- description: register size

Regards,
Jason-JH.Lin

Quoted 25 lines
Quoted 25 lines
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +8 -0
+
   "#clock-cells":
     const: 1
@@ -56,9 +80,16 @@ additionalProperties: false
 
 examples:
   - |
+    #include <dt-bindings/power/mt8173-power.h>
+    #include <dt-bindings/gce/mt8173-gce.h>
+
     mmsys: syscon@14000000 {
         compatible = "mediatek,mt8173-mmsys", "syscon";
         reg = <0x14000000 0x1000>;
+        power-domains = <&spm MT8173_POWER_DOMAIN_MM>;
         #clock-cells = <1>;
         #reset-cells = <1>;
+        mboxes = <&gce 0 CMDQ_THR_PRIO_HIGHEST>,
+                 <&gce 1 CMDQ_THR_PRIO_HIGHEST>;
+        mediatek,gce-client-reg = <&gce SUBSYS_1400XXXX 0 0x1000>;
     };
Signature · 1 line
2.18.0
Signature · 1 line
Jason-JH Lin <[email protected]>
#5 lore raw

PATCH 2/5 dt-bindings: arm: mediatek: mmsys: add mt8195 SoC binding

In reply to Rex-BC Chen

From: "jason-jh.lin" <[email protected]>

In the SoC before, such as mt8173, it has 2 pipelines binding to one mmsys with the same clock driver and the same power domain.

In mt8195, there are 4 pipelines binding to 4 different mmsys, such as vdosys0, vdosys1, vppsys0 and vppsys1.
Each mmsys uses different clock drivers and different power domain.

Since each mmsys has its own mmio base address, they could be identified by their different address during probe time.

---
 .../devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml         | 1 +
 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +1 -0
index 6c2c3edcd443..6ad023eec193 100644
@@ -31,6 +31,7 @@ properties:
               - mediatek,mt8183-mmsys
               - mediatek,mt8186-mmsys
               - mediatek,mt8192-mmsys
+              - mediatek,mt8195-mmsys
               - mediatek,mt8365-mmsys
           - const: syscon
       - items:
Signature · 1 line
2.18.0
maintainer Applied
#6 lore raw

Re: [PATCH 2/5] dt-bindings: arm: mediatek: mmsys: add mt8195 SoC binding

Quoted 9 lines · Rex-BC Chen

From: "jason-jh.lin" <[email protected]>

In the SoC before, such as mt8173, it has 2 pipelines binding to one mmsys with the same clock driver and the same power domain.

In mt8195, there are 4 pipelines binding to 4 different mmsys, such as vdosys0, vdosys1, vppsys0 and vppsys1.
Each mmsys uses different clock drivers and different power domain.

Quoted 6 lines

Since each mmsys has its own mmio base address, they could be identified by their different address during probe time.

Applied, thanks

Quoted 16 lines
---
  .../devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml         | 1 +
  1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml +1 -0
index 6c2c3edcd443..6ad023eec193 100644
@@ -31,6 +31,7 @@ properties:
                - mediatek,mt8183-mmsys
                - mediatek,mt8186-mmsys
                - mediatek,mt8192-mmsys
+              - mediatek,mt8195-mmsys
                - mediatek,mt8365-mmsys
            - const: syscon
        - items:
#7 lore raw

PATCH 3/5 dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195

In reply to Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 RDMA definition.

---
 .../display/mediatek/mediatek,mdp-rdma.yaml   | 86 +++++++++++++++++++
 1 file changed, 86 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +86 -0
new file mode 100644
index 000000000000..6ab773569462
@@ -0,0 +1,86 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/arm/mediatek/mediatek,mdp-rdma.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: MediaTek MDP RDMA
+
+maintainers:
+  - Matthias Brugger <[email protected]>
+
+description: |
+  The mediatek MDP RDMA stands for Read Direct Memory Access.
+  It provides real time data to the back-end panel driver, such as DSI,
+  DPI and DP_INTF.
+  It contains one line buffer to store the sufficient pixel data.
+  RDMA device node must be siblings to the central MMSYS_CONFIG node.
+  For a description of the MMSYS_CONFIG binding, see
+  Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml for details.
+
+properties:
+  compatible:
+    oneOf:
+      - items:
+          - const: mediatek,mt8195-vdo1-rdma
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  power-domains:
+    description: A phandle and PM domain specifier as defined by bindings of
+      the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml for details.
+
+  clocks:
+    items:
+      - description: RDMA Clock
+
+  iommus:
+    description:
+      This property should point to the respective IOMMU block with master port as argument,
+      see Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for details.
+
+  mediatek,gce-client-reg:
+    description:
+      The register of display function block to be set by gce. There are 4 arguments,
+      such as gce node, subsys id, offset and register size. The subsys id that is
+      mapping to the register of display function blocks is defined in the gce header
+      include/include/dt-bindings/gce/<chip>-gce.h of each chips.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - power-domains
+  - clocks
+  - iommus
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        vdo1_rdma0: mdp-rdma@1c104000 {
+            compatible = "mediatek,mt8195-vdo1-rdma";
+            reg = <0 0x1c104000 0 0x1000>;
+            interrupts = <GIC_SPI 495 IRQ_TYPE_LEVEL_HIGH 0>;
+            clocks = <&vdosys1 CLK_VDO1_MDP_RDMA0>;
+            power-domains = <&spm MT8195_POWER_DOMAIN_VDOSYS1>;
+            iommus = <&iommu_vdo M4U_PORT_L2_MDP_RDMA0>;
+            mediatek,gce-client-reg = <&gce0 SUBSYS_1c10XXXX 0x4000 0x1000>;
+        };
+    };
Signature · 1 line
2.18.0
maintainer
#8 lore raw

Re: [PATCH 3/5] dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195

Quoted 11 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 RDMA definition.

---
 .../display/mediatek/mediatek,mdp-rdma.yaml   | 86 +++++++++++++++++++
 1 file changed, 86 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check' on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
./Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml: $id: relative path/filename doesn't match actual path or filename
expected: http://devicetree.org/schemas/display/mediatek/mediatek,mdp-rdma.yaml#
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.example.dts:27:18: fatal error: dt-bindings/memory/mt8195-memory-port.h: No such file or directory
27 | #include <dt-bindings/memory/mt8195-memory-port.h>

      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

compilation terminated.
make[1]: *** [scripts/Makefile.lib:364: Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.example.dtb] Error 1 make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:1401: dt_binding_check] Error 2

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/patch/

This check can fail if there are any dependencies. The base for a patch series is generally the most recent rc1.

If you already ran 'make dt_binding_check' and didn't see the above error(s), then make sure 'yamllint' is installed and dt-schema is up to date:

pip3 install dtschema --upgrade

Please check and re-submit.

#9 lore raw

Re: [PATCH 3/5] dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195

Quoted 52 lines · Rob Herring
Quoted 6 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 RDMA definition.

Reviewed-by AngeloGioacchino Del Regno <
Quoted 9 lines

[email protected]>

---
 .../display/mediatek/mediatek,mdp-rdma.yaml   | 86
+++++++++++++++++++
 1 file changed, 86 insertions(+)
 create mode 100644

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.yaml

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
./Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.yaml: $id: relative path/filename doesn't match actual path or filename
expected:
https://urldefense.com/v3/__http://devicetree.org/schemas/display/mediatek/mediatek,mdp-rdma.yaml*__;Iw!!CTRNKA9wMg0ARbw!3ZfBylOH4GptgXoItZHgYYVPitXIJ1TDhU0oAfMro55Y0xklQB9xVRfnEFl-a1OhDJck$

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.example.dts:27:18: fatal error: dt-bindings/memory/mt8195- memory-port.h: No such file or directory
27 | #include <dt-bindings/memory/mt8195-memory-port.h>

      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

compilation terminated.
make[1]: *** [scripts/Makefile.lib:364:
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.example.dtb] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:1401: dt_binding_check] Error 2

doc reference errors (make refcheckdocs):

See
https://urldefense.com/v3/__https://patchwork.ozlabs.org/patch/__;!!CTRNKA9wMg0ARbw!3ZfBylOH4GptgXoItZHgYYVPitXIJ1TDhU0oAfMro55Y0xklQB9xVRfnEFl-a3heEKEl$

This check can fail if there are any dependencies. The base for a patch
series is generally the most recent rc1.

Quoted 9 lines

If you already ran 'make dt_binding_check' and didn't see the above error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit.

Hello Rob,

As mentioned in cover letter, this patch is basd on Yong's patch:
message id: [email protected] Without this patch, some patches of this series will build failed.

For Yong's series, I think it's just waiting for accepted by maintainers.
Moreover, we really need your suggestion and even approvement for these display binding patches.

Thanks for your big support!

BRs,
Rex

maintainer
#10 lore raw

Re: [PATCH 3/5] dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195

In reply to Rex-BC Chen
Quoted 17 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 RDMA definition.

---
  .../display/mediatek/mediatek,mdp-rdma.yaml   | 86 +++++++++++++++++++
  1 file changed, 86 insertions(+)

create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +0 -0
new file mode 100644
index 000000000000..6ab773569462

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml line 10

Quoted 10 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +10 -0
@@ -0,0 +1,86 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/arm/mediatek/mediatek,mdp-rdma.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: MediaTek MDP RDMA
+
+maintainers:
+  - Matthias Brugger <[email protected]>

I don't think I would be the correct person to maintain this. This should be the person that is maintaining the driver.

Regards,
Matthias

Quoted 76 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +76 -0
+
+description: |
+  The mediatek MDP RDMA stands for Read Direct Memory Access.
+  It provides real time data to the back-end panel driver, such as DSI,
+  DPI and DP_INTF.
+  It contains one line buffer to store the sufficient pixel data.
+  RDMA device node must be siblings to the central MMSYS_CONFIG node.
+  For a description of the MMSYS_CONFIG binding, see
+  Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml for details.
+
+properties:
+  compatible:
+    oneOf:
+      - items:
+          - const: mediatek,mt8195-vdo1-rdma
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  power-domains:
+    description: A phandle and PM domain specifier as defined by bindings of
+      the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml for details.
+
+  clocks:
+    items:
+      - description: RDMA Clock
+
+  iommus:
+    description:
+      This property should point to the respective IOMMU block with master port as argument,
+      see Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for details.
+
+  mediatek,gce-client-reg:
+    description:
+      The register of display function block to be set by gce. There are 4 arguments,
+      such as gce node, subsys id, offset and register size. The subsys id that is
+      mapping to the register of display function blocks is defined in the gce header
+      include/include/dt-bindings/gce/<chip>-gce.h of each chips.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - power-domains
+  - clocks
+  - iommus
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        vdo1_rdma0: mdp-rdma@1c104000 {
+            compatible = "mediatek,mt8195-vdo1-rdma";
+            reg = <0 0x1c104000 0 0x1000>;
+            interrupts = <GIC_SPI 495 IRQ_TYPE_LEVEL_HIGH 0>;
+            clocks = <&vdosys1 CLK_VDO1_MDP_RDMA0>;
+            power-domains = <&spm MT8195_POWER_DOMAIN_VDOSYS1>;
+            iommus = <&iommu_vdo M4U_PORT_L2_MDP_RDMA0>;
+            mediatek,gce-client-reg = <&gce0 SUBSYS_1c10XXXX 0x4000 0x1000>;
+        };
+    };
maintainer
#11 lore raw

Re: [PATCH 3/5] dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195

Matthias Brugger <[email protected]> 於 2022年4月19日 週二 下午10:57寫道:

Quoted 26 lines · Rex-BC Chen
Quoted 22 lines

From: "Nancy.Lin" <[email protected]>

Add vdosys1 RDMA definition.

---
  .../display/mediatek/mediatek,mdp-rdma.yaml   | 86 +++++++++++++++++++
  1 file changed, 86 insertions(+)

create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +5 -0
new file mode 100644
index 000000000000..6ab773569462
@@ -0,0 +1,86 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/arm/mediatek/mediatek,mdp-rdma.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
Quoted 8 lines

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml line 10

Quoted 5 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +5 -0
+
+title: MediaTek MDP RDMA
+
+maintainers:
+  - Matthias Brugger <[email protected]>

I don't think I would be the correct person to maintain this. This should be the person that is maintaining the driver.

Agree. This should be

Chun-Kuang Hu <[email protected]>
Philipp Zabel <[email protected]>

Regards,
Chun-Kuang.

Quoted 80 lines

Regards,
Matthias

Quoted 76 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +76 -0
+
+description: |
+  The mediatek MDP RDMA stands for Read Direct Memory Access.
+  It provides real time data to the back-end panel driver, such as DSI,
+  DPI and DP_INTF.
+  It contains one line buffer to store the sufficient pixel data.
+  RDMA device node must be siblings to the central MMSYS_CONFIG node.
+  For a description of the MMSYS_CONFIG binding, see
+  Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml for details.
+
+properties:
+  compatible:
+    oneOf:
+      - items:
+          - const: mediatek,mt8195-vdo1-rdma
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  power-domains:
+    description: A phandle and PM domain specifier as defined by bindings of
+      the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml for details.
+
+  clocks:
+    items:
+      - description: RDMA Clock
+
+  iommus:
+    description:
+      This property should point to the respective IOMMU block with master port as argument,
+      see Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for details.
+
+  mediatek,gce-client-reg:
+    description:
+      The register of display function block to be set by gce. There are 4 arguments,
+      such as gce node, subsys id, offset and register size. The subsys id that is
+      mapping to the register of display function blocks is defined in the gce header
+      include/include/dt-bindings/gce/<chip>-gce.h of each chips.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - power-domains
+  - clocks
+  - iommus
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        vdo1_rdma0: mdp-rdma@1c104000 {
+            compatible = "mediatek,mt8195-vdo1-rdma";
+            reg = <0 0x1c104000 0 0x1000>;
+            interrupts = <GIC_SPI 495 IRQ_TYPE_LEVEL_HIGH 0>;
+            clocks = <&vdosys1 CLK_VDO1_MDP_RDMA0>;
+            power-domains = <&spm MT8195_POWER_DOMAIN_VDOSYS1>;
+            iommus = <&iommu_vdo M4U_PORT_L2_MDP_RDMA0>;
+            mediatek,gce-client-reg = <&gce0 SUBSYS_1c10XXXX 0x4000 0x1000>;
+        };
+    };
#12 lore raw

Re: [PATCH 3/5] dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195

Quoted 51 lines · Chun-Kuang Hu

Matthias Brugger <[email protected]> 於 2022年4月19日 週二 下午10:57寫道:

Quoted 40 lines · Rex-BC Chen
Quoted 36 lines

From: "Nancy.Lin" <[email protected]>

Add vdosys1 RDMA definition.

Reviewed-by AngeloGioacchino Del Regno <

[email protected]>

---
  .../display/mediatek/mediatek,mdp-rdma.yaml   | 86
+++++++++++++++++++
  1 file changed, 86 insertions(+)

create mode 100644
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.yaml

diff --git a/Documentation/devicetree/bindings/display/mediatek/mediatek,mdp -rdma.yaml b/Documentation/devicetree/bindings/display/mediatek/mediatek,mdp -rdma.yaml
new file mode 100644
index 000000000000..6ab773569462
--- /dev/null
+++
b/Documentation/devicetree/bindings/display/mediatek/mediatek,mdp

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +4 -1
-rdma.yaml
@@ -0,0 +1,86 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: 

https://urldefense.com/v3/__http://devicetree.org/schemas/arm/mediatek/mediatek,mdp-rdma.yaml*__;Iw!!CTRNKA9wMg0ARbw!2Ig4llRcam253qgvT99ty3TWC4Yo6D6Dy1DgFiNuA_fMhtu1lJHERS1f4pzOBELsqIl__FAiHl5bJCAJqNc7FAWGTw$

+$schema:
https://urldefense.com/v3/__http://devicetree.org/meta-schemas/core.yaml*__;Iw!!CTRNKA9wMg0ARbw!2Ig4llRcam253qgvT99ty3TWC4Yo6D6Dy1DgFiNuA_fMhtu1lJHERS1f4pzOBELsqIl__FAiHl5bJCAJqNdU9sgsvg$

Quoted 9 lines

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml line 10

Quoted 5 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +5 -0
+
+title: MediaTek MDP RDMA
+
+maintainers:
+  - Matthias Brugger <[email protected]>

I don't think I would be the correct person to maintain this. This should be the
person that is maintaining the driver.

Quoted 12 lines

Agree. This should be

Chun-Kuang Hu <[email protected]>
Philipp Zabel <[email protected]>

Regards,
Chun-Kuang.

Quoted 4 lines

Regards,
Matthias

Hello Chun-Kuang and Matthias,

OK, I will update the list in next version.

BRs,
Rex

Quoted 90 lines
Quoted 90 lines
Quoted 90 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +4 -0
+
+description: |
+  The mediatek MDP RDMA stands for Read Direct Memory Access.
+  It provides real time data to the back-end panel driver, such

as DSI,

(quoted diff) +2 -0
+  DPI and DP_INTF.
+  It contains one line buffer to store the sufficient pixel

data.
+ RDMA device node must be siblings to the central MMSYS_CONFIG node.

(quoted diff) +2 -0
+  For a description of the MMSYS_CONFIG binding, see
+  Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.

yaml for details.

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +15 -0
+
+properties:
+  compatible:
+    oneOf:
+      - items:
+          - const: mediatek,mt8195-vdo1-rdma
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  power-domains:
+    description: A phandle and PM domain specifier as defined by

bindings of

(quoted diff) +2 -0
+      the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml

for details.

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +8 -0
+
+  clocks:
+    items:
+      - description: RDMA Clock
+
+  iommus:
+    description:
+      This property should point to the respective IOMMU block

with master port as argument,
+ see
Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for details.

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +4 -0
+
+  mediatek,gce-client-reg:
+    description:
+      The register of display function block to be set by gce.

There are 4 arguments,
+ such as gce node, subsys id, offset and register size. The
subsys id that is
+ mapping to the register of display function blocks is
defined in the gce header
+ include/include/dt-bindings/gce/<chip>-gce.h of each
chips.

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +32 -0
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - power-domains
+  - clocks
+  - iommus
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        vdo1_rdma0: mdp-rdma@1c104000 {
+            compatible = "mediatek,mt8195-vdo1-rdma";
+            reg = <0 0x1c104000 0 0x1000>;
+            interrupts = <GIC_SPI 495 IRQ_TYPE_LEVEL_HIGH 0>;
+            clocks = <&vdosys1 CLK_VDO1_MDP_RDMA0>;
+            power-domains = <&spm MT8195_POWER_DOMAIN_VDOSYS1>;
+            iommus = <&iommu_vdo M4U_PORT_L2_MDP_RDMA0>;
+            mediatek,gce-client-reg = <&gce0 SUBSYS_1c10XXXX

0x4000 0x1000>;

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +2 -0
+        };
+    };
maintainer
#13 lore raw

Re: [PATCH 3/5] dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195

In reply to Rex-BC Chen
Quoted 3 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 RDMA definition.

How does this compare to the mediatek,mt8183-mdp3-rdma or mediatek,mt8195-disp-rdma?

Quoted 104 lines
---
 .../display/mediatek/mediatek,mdp-rdma.yaml   | 86 +++++++++++++++++++
 1 file changed, 86 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml
Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +86 -0
new file mode 100644
index 000000000000..6ab773569462
@@ -0,0 +1,86 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/arm/mediatek/mediatek,mdp-rdma.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: MediaTek MDP RDMA
+
+maintainers:
+  - Matthias Brugger <[email protected]>
+
+description: |
+  The mediatek MDP RDMA stands for Read Direct Memory Access.
+  It provides real time data to the back-end panel driver, such as DSI,
+  DPI and DP_INTF.
+  It contains one line buffer to store the sufficient pixel data.
+  RDMA device node must be siblings to the central MMSYS_CONFIG node.
+  For a description of the MMSYS_CONFIG binding, see
+  Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.yaml for details.
+
+properties:
+  compatible:
+    oneOf:
+      - items:
+          - const: mediatek,mt8195-vdo1-rdma
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  power-domains:
+    description: A phandle and PM domain specifier as defined by bindings of
+      the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml for details.
+
+  clocks:
+    items:
+      - description: RDMA Clock
+
+  iommus:
+    description:
+      This property should point to the respective IOMMU block with master port as argument,
+      see Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for details.
+
+  mediatek,gce-client-reg:
+    description:
+      The register of display function block to be set by gce. There are 4 arguments,
+      such as gce node, subsys id, offset and register size. The subsys id that is
+      mapping to the register of display function blocks is defined in the gce header
+      include/include/dt-bindings/gce/<chip>-gce.h of each chips.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - power-domains
+  - clocks
+  - iommus
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        vdo1_rdma0: mdp-rdma@1c104000 {
+            compatible = "mediatek,mt8195-vdo1-rdma";
+            reg = <0 0x1c104000 0 0x1000>;
+            interrupts = <GIC_SPI 495 IRQ_TYPE_LEVEL_HIGH 0>;
+            clocks = <&vdosys1 CLK_VDO1_MDP_RDMA0>;
+            power-domains = <&spm MT8195_POWER_DOMAIN_VDOSYS1>;
+            iommus = <&iommu_vdo M4U_PORT_L2_MDP_RDMA0>;
+            mediatek,gce-client-reg = <&gce0 SUBSYS_1c10XXXX 0x4000 0x1000>;
+        };
+    };
Signature · 1 line
2.18.0
#14 lore raw

Re: [PATCH 3/5] dt-bindings: mediatek: add vdosys1 RDMA definition for mt8195

Hi Rob,

Thanks for the review.

Quoted 8 lines · Rob Herring
Quoted 3 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 RDMA definition.

How does this compare to the mediatek,mt8183-mdp3-rdma or mediatek,mt8195-disp-rdma?

1. The mediatek,mt8195-vdo1-rdma is a completely different HW engine with mediatek,mt8195-disp-rdma.
2. The mediatek,mt8195-vdo1-rdma is similar to mt8183-mdp3-rdma but with different compression support and tile size.

Regards,
Nancy

Quoted 130 lines
Quoted 130 lines
Reviewed-by AngeloGioacchino Del Regno <

[email protected]>

---
 .../display/mediatek/mediatek,mdp-rdma.yaml   | 86
+++++++++++++++++++
 1 file changed, 86 insertions(+)
 create mode 100644

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.yaml

diff --git a/Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.yaml b/Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.yaml
new file mode 100644
index 000000000000..6ab773569462
--- /dev/null
+++
b/Documentation/devicetree/bindings/display/mediatek/mediatek,mdp- rdma.yaml

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +4 -0
@@ -0,0 +1,86 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: 

https://urldefense.com/v3/__http://devicetree.org/schemas/arm/mediatek/mediatek,mdp-rdma.yaml*__;Iw!!CTRNKA9wMg0ARbw!2wDOMpaEiBxKqnxB_Ocy9EiZEBgMnMmhgp0QxtKsUv2WjEbcBxe1P0gILWVkqZ2k$

+$schema:
https://urldefense.com/v3/__http://devicetree.org/meta-schemas/core.yaml*__;Iw!!CTRNKA9wMg0ARbw!2wDOMpaEiBxKqnxB_Ocy9EiZEBgMnMmhgp0QxtKsUv2WjEbcBxe1P0gILfySwMCt$

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +9 -0
+
+title: MediaTek MDP RDMA
+
+maintainers:
+  - Matthias Brugger <[email protected]>
+
+description: |
+  The mediatek MDP RDMA stands for Read Direct Memory Access.
+  It provides real time data to the back-end panel driver, such as

DSI,

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +3 -0
+  DPI and DP_INTF.
+  It contains one line buffer to store the sufficient pixel data.
+  RDMA device node must be siblings to the central MMSYS_CONFIG

node.

(quoted diff) +2 -0
+  For a description of the MMSYS_CONFIG binding, see
+  Documentation/devicetree/bindings/arm/mediatek/mediatek,mmsys.ya

ml for details.

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +15 -0
+
+properties:
+  compatible:
+    oneOf:
+      - items:
+          - const: mediatek,mt8195-vdo1-rdma
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  power-domains:
+    description: A phandle and PM domain specifier as defined by

bindings of

(quoted diff) +2 -0
+      the power controller specified by phandle. See
+      Documentation/devicetree/bindings/power/power-domain.yaml

for details.

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +8 -0
+
+  clocks:
+    items:
+      - description: RDMA Clock
+
+  iommus:
+    description:
+      This property should point to the respective IOMMU block

with master port as argument,
+ see
Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for details.

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +4 -0
+
+  mediatek,gce-client-reg:
+    description:
+      The register of display function block to be set by gce.

There are 4 arguments,
+ such as gce node, subsys id, offset and register size. The
subsys id that is
+ mapping to the register of display function blocks is
defined in the gce header

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +33 -0
+      include/include/dt-bindings/gce/<chip>-gce.h of each chips.
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - power-domains
+  - clocks
+  - iommus
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        vdo1_rdma0: mdp-rdma@1c104000 {
+            compatible = "mediatek,mt8195-vdo1-rdma";
+            reg = <0 0x1c104000 0 0x1000>;
+            interrupts = <GIC_SPI 495 IRQ_TYPE_LEVEL_HIGH 0>;
+            clocks = <&vdosys1 CLK_VDO1_MDP_RDMA0>;
+            power-domains = <&spm MT8195_POWER_DOMAIN_VDOSYS1>;
+            iommus = <&iommu_vdo M4U_PORT_L2_MDP_RDMA0>;
+            mediatek,gce-client-reg = <&gce0 SUBSYS_1c10XXXX

0x4000 0x1000>;

Documentation/devicetree/bindings/display/mediatek/mediatek,mdp-rdma.yaml new file +2 -0
+        };
+    };
Signature · 1 line
2.18.0
#15 lore raw

PATCH 4/5 dt-bindings: reset: mt8195: add vdosys1 reset control bit

In reply to Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 reset control bit for MT8195 platform.

---
 include/dt-bindings/reset/mt8195-resets.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)
include/dt-bindings/reset/mt8195-resets.h +12 -0
index a26bccc8b957..aab8d74496a6 100644
@@ -26,4 +26,16 @@
 
 #define MT8195_TOPRGU_SW_RST_NUM               16
 
+/* VDOSYS1 */
+#define MT8195_VDOSYS1_SW0_RST_B_MERGE0_DL_ASYNC          25
+#define MT8195_VDOSYS1_SW0_RST_B_MERGE1_DL_ASYNC          26
+#define MT8195_VDOSYS1_SW0_RST_B_MERGE2_DL_ASYNC          27
+#define MT8195_VDOSYS1_SW0_RST_B_MERGE3_DL_ASYNC          28
+#define MT8195_VDOSYS1_SW0_RST_B_MERGE4_DL_ASYNC          29
+#define MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_FE0_DL_ASYNC     51
+#define MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_FE1_DL_ASYNC     52
+#define MT8195_VDOSYS1_SW1_RST_B_HDR_GFX_FE0_DL_ASYNC     53
+#define MT8195_VDOSYS1_SW1_RST_B_HDR_GFX_FE1_DL_ASYNC     54
+#define MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_BE_DL_ASYNC      55
+
 #endif  /* _DT_BINDINGS_RESET_CONTROLLER_MT8195 */
Signature · 1 line
2.18.0
#16 lore raw

PATCH 5/5 dt-bindings: mediatek: add ethdr definition for mt8195

In reply to Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 ETHDR definition.

---
 .../display/mediatek/mediatek,ethdr.yaml      | 158 ++++++++++++++++++
 1 file changed, 158 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +158 -0
new file mode 100644
index 000000000000..e8303c28a361
@@ -0,0 +1,158 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/display/mediatek/mediatek,ethdr.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: MediaTek Ethdr Device Tree Bindings
+
+maintainers:
+  - Chun-Kuang Hu <[email protected]>
+  - Philipp Zabel <[email protected]>
+
+description: |
+  ETHDR is designed for HDR video and graphics conversion in the external display path.
+  It handles multiple HDR input types and performs tone mapping, color space/color
+  format conversion, and then combine different layers, output the required HDR or
+  SDR signal to the subsequent display path. This engine is composed of two video
+  frontends, two graphic frontends, one video backend and a mixer. ETHDR has two
+  DMA function blocks, DS and ADL. These two function blocks read the pre-programmed
+  registers from DRAM and set them to HW in the v-blanking period.
+
+properties:
+  compatible:
+    items:
+      - const: mediatek,mt8195-disp-ethdr
+  reg:
+    maxItems: 7
+  reg-names:
+    items:
+      - const: mixer
+      - const: vdo_fe0
+      - const: vdo_fe1
+      - const: gfx_fe0
+      - const: gfx_fe1
+      - const: vdo_be
+      - const: adl_ds
+  interrupts:
+    minItems: 1
+  iommus:
+    description: The compatible property is DMA function blocks.
+      Should point to the respective IOMMU block with master port as argument,
+      see Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for
+      details.
+    minItems: 1
+    maxItems: 2
+  clocks:
+    items:
+      - description: mixer clock
+      - description: video frontend 0 clock
+      - description: video frontend 1 clock
+      - description: graphic frontend 0 clock
+      - description: graphic frontend 1 clock
+      - description: video backend clock
+      - description: autodownload and menuload clock
+      - description: video frontend 0 async clock
+      - description: video frontend 1 async clock
+      - description: graphic frontend 0 async clock
+      - description: graphic frontend 1 async clock
+      - description: video backend async clock
+      - description: ethdr top clock
+  clock-names:
+    items:
+      - const: mixer
+      - const: vdo_fe0
+      - const: vdo_fe1
+      - const: gfx_fe0
+      - const: gfx_fe1
+      - const: vdo_be
+      - const: adl_ds
+      - const: vdo_fe0_async
+      - const: vdo_fe1_async
+      - const: gfx_fe0_async
+      - const: gfx_fe1_async
+      - const: vdo_be_async
+      - const: ethdr_top
+  power-domains:
+    maxItems: 1
+  resets:
+    maxItems: 5
+  mediatek,gce-client-reg:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description: The register of display function block to be set by gce.
+      There are 4 arguments in this property, gce node, subsys id, offset and
+      register size. The subsys id is defined in the gce header of each chips
+      include/include/dt-bindings/gce/<chip>-gce.h, mapping to the register of
+      display function block.
+
+required:
+  - compatible
+  - reg
+  - clocks
+  - clock-names
+  - interrupts
+  - power-domains
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/reset/mt8195-resets.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        disp_ethdr@1c114000 {
+                compatible = "mediatek,mt8195-disp-ethdr";
+                reg = <0 0x1c114000 0 0x1000>,
+                      <0 0x1c115000 0 0x1000>,
+                      <0 0x1c117000 0 0x1000>,
+                      <0 0x1c119000 0 0x1000>,
+                      <0 0x1c11a000 0 0x1000>,
+                      <0 0x1c11b000 0 0x1000>,
+                      <0 0x1c11b000 0 0x1000>;
+                reg-names = "mixer", "vdo_fe0", "vdo_fe1", "gfx_fe0", "gfx_fe1",
+                            "vdo_be", "adl_ds";
+                mediatek,gce-client-reg = <&gce0 SUBSYS_1c11XXXX 0x4000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0x5000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0x7000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0x9000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0xa000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0xb000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0xc000 0x1000>;
+                clocks = <&vdosys1 CLK_VDO1_DISP_MIXER>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE0>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE1>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE0>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE1>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_BE>,
+                         <&vdosys1 CLK_VDO1_26M_SLOW>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE0_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE1_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE0_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE1_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_BE_DL_ASYNC>,
+                         <&topckgen CLK_TOP_ETHDR>;
+                clock-names = "mixer", "vdo_fe0", "vdo_fe1", "gfx_fe0", "gfx_fe1",
+                              "vdo_be", "adl_ds", "vdo_fe0_async", "vdo_fe1_async",
+                              "gfx_fe0_async", "gfx_fe1_async","vdo_be_async",
+                              "ethdr_top";
+                power-domains = <&spm MT8195_POWER_DOMAIN_VDOSYS1>;
+                iommus = <&iommu_vpp M4U_PORT_L3_HDR_DS>,
+                         <&iommu_vpp M4U_PORT_L3_HDR_ADL>;
+                interrupts = <GIC_SPI 517 IRQ_TYPE_LEVEL_HIGH 0>; /* disp mixer */
+                resets = <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_FE0_DL_ASYNC>,
+                         <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_FE1_DL_ASYNC>,
+                         <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_GFX_FE0_DL_ASYNC>,
+                         <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_GFX_FE1_DL_ASYNC>,
+                         <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_BE_DL_ASYNC>;
+        };
+    };
+
+...
Signature · 1 line
2.18.0
maintainer
#17 lore raw

Re: [PATCH 5/5] dt-bindings: mediatek: add ethdr definition for mt8195

Quoted 4 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 ETHDR definition.

Quoted 8 lines
---
 .../display/mediatek/mediatek,ethdr.yaml      | 158 ++++++++++++++++++
 1 file changed, 158 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check' on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.example.dts:26:18: fatal error: dt-bindings/memory/mt8195-memory-port.h: No such file or directory
26 | #include <dt-bindings/memory/mt8195-memory-port.h>

      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

compilation terminated.
make[1]: *** [scripts/Makefile.lib:364: Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.example.dtb] Error 1 make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:1401: dt_binding_check] Error 2

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/patch/

This check can fail if there are any dependencies. The base for a patch series is generally the most recent rc1.

If you already ran 'make dt_binding_check' and didn't see the above error(s), then make sure 'yamllint' is installed and dt-schema is up to date:

pip3 install dtschema --upgrade

Please check and re-submit.

#18 lore raw

Re: [PATCH 5/5] dt-bindings: mediatek: add ethdr definition for mt8195

Quoted 47 lines · Rob Herring
Quoted 7 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 ETHDR definition.

Reviewed-by AngeloGioacchino Del Regno <
Quoted 9 lines

[email protected]>

---
 .../display/mediatek/mediatek,ethdr.yaml      | 158
++++++++++++++++++
 1 file changed, 158 insertions(+)
 create mode 100644

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.y aml

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.exa mple.dts:26:18: fatal error: dt-bindings/memory/mt8195-memory-port.h:
No such file or directory
26 | #include <dt-bindings/memory/mt8195-memory-port.h>

      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

compilation terminated.
make[1]: *** [scripts/Makefile.lib:364:
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.exa mple.dtb] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:1401: dt_binding_check] Error 2

doc reference errors (make refcheckdocs):

See
https://urldefense.com/v3/__https://patchwork.ozlabs.org/patch/__;!!CTRNKA9wMg0ARbw!0_37wgtYvnR9SOpuvHJTNoD49ZH-H-8wVYtuCNFWbusuETEVY3vuSBeQz424H8e4_VNF3DOx4RmpXtN3gVegfPw1Hw$

This check can fail if there are any dependencies. The base for a patch
series is generally the most recent rc1.

Quoted 9 lines

If you already ran 'make dt_binding_check' and didn't see the above error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit.

Hello Rob,

As mentioned in [3/5], this patch is also basd on Yong's patch:
message id: [email protected] Without this patch, some patches of this series will build failed.

Thanks!

BRs,
Rex

maintainer
#19 lore raw

Re: [PATCH 5/5] dt-bindings: mediatek: add ethdr definition for mt8195

In reply to Rex-BC Chen
Quoted 21 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 ETHDR definition.

---
 .../display/mediatek/mediatek,ethdr.yaml      | 158 ++++++++++++++++++
 1 file changed, 158 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +3 -0
new file mode 100644
index 000000000000..e8303c28a361
@@ -0,0 +1,158 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 13

Quoted 10 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +10 -0
+$id: http://devicetree.org/schemas/display/mediatek/mediatek,ethdr.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: MediaTek Ethdr Device Tree Bindings
+
+maintainers:
+  - Chun-Kuang Hu <[email protected]>
+  - Philipp Zabel <[email protected]>
+
+description: |

No need for '|' unless you have formatting to preserve.

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 25

Quoted 12 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +12 -0
+  ETHDR is designed for HDR video and graphics conversion in the external display path.
+  It handles multiple HDR input types and performs tone mapping, color space/color
+  format conversion, and then combine different layers, output the required HDR or
+  SDR signal to the subsequent display path. This engine is composed of two video
+  frontends, two graphic frontends, one video backend and a mixer. ETHDR has two
+  DMA function blocks, DS and ADL. These two function blocks read the pre-programmed
+  registers from DRAM and set them to HW in the v-blanking period.
+
+properties:
+  compatible:
+    items:
+      - const: mediatek,mt8195-disp-ethdr

blank line between DT properties.

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 38

Quoted 13 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +13 -0
+  reg:
+    maxItems: 7
+  reg-names:
+    items:
+      - const: mixer
+      - const: vdo_fe0
+      - const: vdo_fe1
+      - const: gfx_fe0
+      - const: gfx_fe1
+      - const: vdo_be
+      - const: adl_ds
+  interrupts:
+    minItems: 1

maxItems: 1

Quoted 31 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +31 -0
+  iommus:
+    description: The compatible property is DMA function blocks.
+      Should point to the respective IOMMU block with master port as argument,
+      see Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for
+      details.
+    minItems: 1
+    maxItems: 2
+  clocks:
+    items:
+      - description: mixer clock
+      - description: video frontend 0 clock
+      - description: video frontend 1 clock
+      - description: graphic frontend 0 clock
+      - description: graphic frontend 1 clock
+      - description: video backend clock
+      - description: autodownload and menuload clock
+      - description: video frontend 0 async clock
+      - description: video frontend 1 async clock
+      - description: graphic frontend 0 async clock
+      - description: graphic frontend 1 async clock
+      - description: video backend async clock
+      - description: ethdr top clock
+  clock-names:
+    items:
+      - const: mixer
+      - const: vdo_fe0
+      - const: vdo_fe1
+      - const: gfx_fe0
+      - const: gfx_fe1
+      - const: vdo_be
+      - const: adl_ds

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 79

Quoted 10 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +10 -0
+      - const: vdo_fe0_async
+      - const: vdo_fe1_async
+      - const: gfx_fe0_async
+      - const: gfx_fe1_async
+      - const: vdo_be_async
+      - const: ethdr_top
+  power-domains:
+    maxItems: 1
+  resets:
+    maxItems: 5

Need to define what they are and order.

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 86

Quoted 7 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +7 -0
+  mediatek,gce-client-reg:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description: The register of display function block to be set by gce.
+      There are 4 arguments in this property, gce node, subsys id, offset and
+      register size. The subsys id is defined in the gce header of each chips
+      include/include/dt-bindings/gce/<chip>-gce.h, mapping to the register of
+      display function block.

Need to define each cell:

minItems: ??
maxItems: ??
items:
items:
- description: gce node
- description: ...
...

Seems odd this property is optional...

Quoted 76 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +72 -0
+
+required:
+  - compatible
+  - reg
+  - clocks
+  - clock-names
+  - interrupts
+  - power-domains
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/reset/mt8195-resets.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        disp_ethdr@1c114000 {
+                compatible = "mediatek,mt8195-disp-ethdr";
+                reg = <0 0x1c114000 0 0x1000>,
+                      <0 0x1c115000 0 0x1000>,
+                      <0 0x1c117000 0 0x1000>,
+                      <0 0x1c119000 0 0x1000>,
+                      <0 0x1c11a000 0 0x1000>,
+                      <0 0x1c11b000 0 0x1000>,
+                      <0 0x1c11b000 0 0x1000>;
+                reg-names = "mixer", "vdo_fe0", "vdo_fe1", "gfx_fe0", "gfx_fe1",
+                            "vdo_be", "adl_ds";
+                mediatek,gce-client-reg = <&gce0 SUBSYS_1c11XXXX 0x4000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0x5000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0x7000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0x9000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0xa000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0xb000 0x1000>,
+                                          <&gce0 SUBSYS_1c11XXXX 0xc000 0x1000>;
+                clocks = <&vdosys1 CLK_VDO1_DISP_MIXER>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE0>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE1>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE0>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE1>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_BE>,
+                         <&vdosys1 CLK_VDO1_26M_SLOW>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE0_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE1_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE0_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE1_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_BE_DL_ASYNC>,
+                         <&topckgen CLK_TOP_ETHDR>;
+                clock-names = "mixer", "vdo_fe0", "vdo_fe1", "gfx_fe0", "gfx_fe1",
+                              "vdo_be", "adl_ds", "vdo_fe0_async", "vdo_fe1_async",
+                              "gfx_fe0_async", "gfx_fe1_async","vdo_be_async",
+                              "ethdr_top";
+                power-domains = <&spm MT8195_POWER_DOMAIN_VDOSYS1>;
+                iommus = <&iommu_vpp M4U_PORT_L3_HDR_DS>,
+                         <&iommu_vpp M4U_PORT_L3_HDR_ADL>;
+                interrupts = <GIC_SPI 517 IRQ_TYPE_LEVEL_HIGH 0>; /* disp mixer */
+                resets = <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_FE0_DL_ASYNC>,
+                         <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_FE1_DL_ASYNC>,
+                         <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_GFX_FE0_DL_ASYNC>,
+                         <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_GFX_FE1_DL_ASYNC>,
+                         <&vdosys1 MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_BE_DL_ASYNC>;
+        };
+    };
+
+...
Signature · 1 line
2.18.0
#20 lore raw

Re: [PATCH 5/5] dt-bindings: mediatek: add ethdr definition for mt8195

Hi Rob,

Thanks for the review.

Quoted 38 lines · Rob Herring
Quoted 37 lines · Rex-BC Chen

From: "Nancy.Lin" <[email protected]>

Add vdosys1 ETHDR definition.

Reviewed-by AngeloGioacchino Del Regno <

[email protected]>

---
 .../display/mediatek/mediatek,ethdr.yaml      | 158
++++++++++++++++++
 1 file changed, 158 insertions(+)
 create mode 100644

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.y aml

diff --git a/Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr .yaml b/Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr .yaml
new file mode 100644
index 000000000000..e8303c28a361
--- /dev/null
+++
b/Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr .yaml

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +4 -0
@@ -0,0 +1,158 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: 

https://urldefense.com/v3/__http://devicetree.org/schemas/display/mediatek/mediatek,ethdr.yaml*__;Iw!!CTRNKA9wMg0ARbw!z6Qb786guKB3dY5cad1rD-jjAKgb98adNO0iLltNXsUykBP5Dsa0vYrk8jqJVUow$

+$schema:
https://urldefense.com/v3/__http://devicetree.org/meta-schemas/core.yaml*__;Iw!!CTRNKA9wMg0ARbw!z6Qb786guKB3dY5cad1rD-jjAKgb98adNO0iLltNXsUykBP5Dsa0vYrk8uKJDTkb$

Quoted 11 lines

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 13

Quoted 8 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +8 -0
+
+title: MediaTek Ethdr Device Tree Bindings
+
+maintainers:
+  - Chun-Kuang Hu <[email protected]>
+  - Philipp Zabel <[email protected]>
+
+description: |

No need for '|' unless you have formatting to preserve.

OK, I will remove it.

Quoted 12 lines
Quoted 12 lines

+ ETHDR is designed for HDR video and graphics conversion in the external display path.
+ It handles multiple HDR input types and performs tone mapping, color space/color
+ format conversion, and then combine different layers, output the required HDR or
+ SDR signal to the subsequent display path. This engine is composed of two video
+ frontends, two graphic frontends, one video backend and a mixer. ETHDR has two
+ DMA function blocks, DS and ADL. These two function blocks read the pre-programmed

Quoted 8 lines

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 25

Quoted 6 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +6 -0
+  registers from DRAM and set them to HW in the v-blanking period.
+
+properties:
+  compatible:
+    items:
+      - const: mediatek,mt8195-disp-ethdr

blank line between DT properties.

OK, I will add blank line between DT properties.

Quoted 15 lines
Quoted 4 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +3 -0
+  reg:
+    maxItems: 7
+  reg-names:

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 38

Quoted 10 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +10 -0
+    items:
+      - const: mixer
+      - const: vdo_fe0
+      - const: vdo_fe1
+      - const: gfx_fe0
+      - const: gfx_fe1
+      - const: vdo_be
+      - const: adl_ds
+  interrupts:
+    minItems: 1
Quoted 2 lines

maxItems: 1

OK, I will fix it.

Quoted 44 lines
Quoted 33 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +3 -0
+  iommus:
+    description: The compatible property is DMA function blocks.
+      Should point to the respective IOMMU block with master port

as argument,
+ see
Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +27 -0
+      details.
+    minItems: 1
+    maxItems: 2
+  clocks:
+    items:
+      - description: mixer clock
+      - description: video frontend 0 clock
+      - description: video frontend 1 clock
+      - description: graphic frontend 0 clock
+      - description: graphic frontend 1 clock
+      - description: video backend clock
+      - description: autodownload and menuload clock
+      - description: video frontend 0 async clock
+      - description: video frontend 1 async clock
+      - description: graphic frontend 0 async clock
+      - description: graphic frontend 1 async clock
+      - description: video backend async clock
+      - description: ethdr top clock
+  clock-names:
+    items:
+      - const: mixer
+      - const: vdo_fe0
+      - const: vdo_fe1
+      - const: gfx_fe0
+      - const: gfx_fe1
+      - const: vdo_be
+      - const: adl_ds

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml line 79

Quoted 10 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +10 -0
+      - const: vdo_fe0_async
+      - const: vdo_fe1_async
+      - const: gfx_fe0_async
+      - const: gfx_fe1_async
+      - const: vdo_be_async
+      - const: ethdr_top
+  power-domains:
+    maxItems: 1
+  resets:
+    maxItems: 5
Quoted 2 lines

Need to define what they are and order.

OK. I will fix it in the next revision.

Quoted 22 lines
Quoted 11 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +3 -0
+  mediatek,gce-client-reg:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description: The register of display function block to be set

by gce.
+ There are 4 arguments in this property, gce node, subsys id,
offset and
+ register size. The subsys id is defined in the gce header of
each chips
+ include/include/dt-bindings/gce/<chip>-gce.h, mapping to the
register of
+ display function block.

Need to define each cell:

minItems: ??
maxItems: ??
items:
items:
- description: gce node
- description: ...
...

Quoted 2 lines

Seems odd this property is optional...

Yes, I miss the required properties, will fix them.

Since my email server spam problem is fixed. I will send these binding patches in my vdosys1 series [1]. (The fixes will be in the next revision v18)

[1]
https://patchwork.kernel.org/project/linux-mediatek/list/?series=632713

Regards,
Nancy

Quoted 94 lines
Quoted 94 lines
Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +34 -0
+
+required:
+  - compatible
+  - reg
+  - clocks
+  - clock-names
+  - interrupts
+  - power-domains
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/mt8195-clk.h>
+    #include <dt-bindings/gce/mt8195-gce.h>
+    #include <dt-bindings/memory/mt8195-memory-port.h>
+    #include <dt-bindings/power/mt8195-power.h>
+    #include <dt-bindings/reset/mt8195-resets.h>
+
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        disp_ethdr@1c114000 {
+                compatible = "mediatek,mt8195-disp-ethdr";
+                reg = <0 0x1c114000 0 0x1000>,
+                      <0 0x1c115000 0 0x1000>,
+                      <0 0x1c117000 0 0x1000>,
+                      <0 0x1c119000 0 0x1000>,
+                      <0 0x1c11a000 0 0x1000>,
+                      <0 0x1c11b000 0 0x1000>,
+                      <0 0x1c11b000 0 0x1000>;
+                reg-names = "mixer", "vdo_fe0", "vdo_fe1",

"gfx_fe0", "gfx_fe1",

(quoted diff) +2 -0
+                            "vdo_be", "adl_ds";
+                mediatek,gce-client-reg = <&gce0 SUBSYS_1c11XXXX

0x4000 0x1000>,
+ <&gce0 SUBSYS_1c11XXXX
0x5000 0x1000>,
+ <&gce0 SUBSYS_1c11XXXX
0x7000 0x1000>,
+ <&gce0 SUBSYS_1c11XXXX
0x9000 0x1000>,
+ <&gce0 SUBSYS_1c11XXXX
0xa000 0x1000>,
+ <&gce0 SUBSYS_1c11XXXX
0xb000 0x1000>,
+ <&gce0 SUBSYS_1c11XXXX
0xc000 0x1000>;

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +14 -0
+                clocks = <&vdosys1 CLK_VDO1_DISP_MIXER>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE0>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE1>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE0>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE1>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_BE>,
+                         <&vdosys1 CLK_VDO1_26M_SLOW>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE0_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_FE1_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE0_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_GFX_FE1_DL_ASYNC>,
+                         <&vdosys1 CLK_VDO1_HDR_VDO_BE_DL_ASYNC>,
+                         <&topckgen CLK_TOP_ETHDR>;
+                clock-names = "mixer", "vdo_fe0", "vdo_fe1",

"gfx_fe0", "gfx_fe1",
+ "vdo_be", "adl_ds", "vdo_fe0_async",
"vdo_fe1_async",
+ "gfx_fe0_async",
"gfx_fe1_async","vdo_be_async",

(quoted diff) +2 -0
+                              "ethdr_top";
+                power-domains = <&spm

MT8195_POWER_DOMAIN_VDOSYS1>;

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +3 -0
+                iommus = <&iommu_vpp M4U_PORT_L3_HDR_DS>,
+                         <&iommu_vpp M4U_PORT_L3_HDR_ADL>;
+                interrupts = <GIC_SPI 517 IRQ_TYPE_LEVEL_HIGH 0>;

/* disp mixer */
+ resets = <&vdosys1
MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_FE0_DL_ASYNC>,
+ <&vdosys1
MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_FE1_DL_ASYNC>,
+ <&vdosys1
MT8195_VDOSYS1_SW1_RST_B_HDR_GFX_FE0_DL_ASYNC>,
+ <&vdosys1
MT8195_VDOSYS1_SW1_RST_B_HDR_GFX_FE1_DL_ASYNC>,
+ <&vdosys1
MT8195_VDOSYS1_SW1_RST_B_HDR_VDO_BE_DL_ASYNC>;

Documentation/devicetree/bindings/display/mediatek/mediatek,ethdr.yaml new file +4 -0
+        };
+    };
+
+...
Signature · 1 line
2.18.0