17ef62cebSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
27ef62cebSEmmanuel Vadot%YAML 1.2
37ef62cebSEmmanuel Vadot---
47ef62cebSEmmanuel Vadot$id: http://devicetree.org/schemas/media/mediatek,mdp3-wrot.yaml#
57ef62cebSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
67ef62cebSEmmanuel Vadot
77ef62cebSEmmanuel Vadottitle: MediaTek Write DMA with Rotation
87ef62cebSEmmanuel Vadot
97ef62cebSEmmanuel Vadotmaintainers:
107ef62cebSEmmanuel Vadot  - Matthias Brugger <matthias.bgg@gmail.com>
117ef62cebSEmmanuel Vadot  - Moudy Ho <moudy.ho@mediatek.com>
127ef62cebSEmmanuel Vadot
137ef62cebSEmmanuel Vadotdescription: |
147ef62cebSEmmanuel Vadot  One of Media Data Path 3 (MDP3) components used to write DMA with frame rotation.
157ef62cebSEmmanuel Vadot
167ef62cebSEmmanuel Vadotproperties:
177ef62cebSEmmanuel Vadot  compatible:
18*8d13bc63SEmmanuel Vadot    oneOf:
197ef62cebSEmmanuel Vadot      - enum:
207ef62cebSEmmanuel Vadot          - mediatek,mt8183-mdp3-wrot
21*8d13bc63SEmmanuel Vadot      - items:
22*8d13bc63SEmmanuel Vadot          - enum:
23*8d13bc63SEmmanuel Vadot              - mediatek,mt8195-mdp3-wrot
24*8d13bc63SEmmanuel Vadot          - const: mediatek,mt8183-mdp3-wrot
257ef62cebSEmmanuel Vadot
267ef62cebSEmmanuel Vadot  reg:
277ef62cebSEmmanuel Vadot    maxItems: 1
287ef62cebSEmmanuel Vadot
297ef62cebSEmmanuel Vadot  mediatek,gce-client-reg:
307ef62cebSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/phandle-array
317ef62cebSEmmanuel Vadot    items:
327ef62cebSEmmanuel Vadot      items:
337ef62cebSEmmanuel Vadot        - description: phandle of GCE
347ef62cebSEmmanuel Vadot        - description: GCE subsys id
357ef62cebSEmmanuel Vadot        - description: register offset
367ef62cebSEmmanuel Vadot        - description: register size
377ef62cebSEmmanuel Vadot    description: The register of client driver can be configured by gce with
387ef62cebSEmmanuel Vadot      4 arguments defined in this property. Each GCE subsys id is mapping to
397ef62cebSEmmanuel Vadot      a client defined in the header include/dt-bindings/gce/<chip>-gce.h.
407ef62cebSEmmanuel Vadot
417ef62cebSEmmanuel Vadot  mediatek,gce-events:
427ef62cebSEmmanuel Vadot    description:
437ef62cebSEmmanuel Vadot      The event id which is mapping to the specific hardware event signal
447ef62cebSEmmanuel Vadot      to gce. The event id is defined in the gce header
457ef62cebSEmmanuel Vadot      include/dt-bindings/gce/<chip>-gce.h of each chips.
467ef62cebSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/uint32-array
477ef62cebSEmmanuel Vadot
487ef62cebSEmmanuel Vadot  power-domains:
497ef62cebSEmmanuel Vadot    maxItems: 1
507ef62cebSEmmanuel Vadot
517ef62cebSEmmanuel Vadot  clocks:
527ef62cebSEmmanuel Vadot    minItems: 1
537ef62cebSEmmanuel Vadot
547ef62cebSEmmanuel Vadot  iommus:
557ef62cebSEmmanuel Vadot    maxItems: 1
567ef62cebSEmmanuel Vadot
57*8d13bc63SEmmanuel Vadot  '#dma-cells':
58*8d13bc63SEmmanuel Vadot    const: 1
59*8d13bc63SEmmanuel Vadot
607ef62cebSEmmanuel Vadotrequired:
617ef62cebSEmmanuel Vadot  - compatible
627ef62cebSEmmanuel Vadot  - reg
637ef62cebSEmmanuel Vadot  - mediatek,gce-client-reg
647ef62cebSEmmanuel Vadot  - mediatek,gce-events
657ef62cebSEmmanuel Vadot  - power-domains
667ef62cebSEmmanuel Vadot  - clocks
677ef62cebSEmmanuel Vadot  - iommus
68*8d13bc63SEmmanuel Vadot  - '#dma-cells'
697ef62cebSEmmanuel Vadot
707ef62cebSEmmanuel VadotadditionalProperties: false
717ef62cebSEmmanuel Vadot
727ef62cebSEmmanuel Vadotexamples:
737ef62cebSEmmanuel Vadot  - |
747ef62cebSEmmanuel Vadot    #include <dt-bindings/clock/mt8183-clk.h>
757ef62cebSEmmanuel Vadot    #include <dt-bindings/gce/mt8183-gce.h>
767ef62cebSEmmanuel Vadot    #include <dt-bindings/power/mt8183-power.h>
777ef62cebSEmmanuel Vadot    #include <dt-bindings/memory/mt8183-larb-port.h>
787ef62cebSEmmanuel Vadot
79*8d13bc63SEmmanuel Vadot    dma-controller@14005000 {
807ef62cebSEmmanuel Vadot        compatible = "mediatek,mt8183-mdp3-wrot";
817ef62cebSEmmanuel Vadot        reg = <0x14005000 0x1000>;
827ef62cebSEmmanuel Vadot        mediatek,gce-client-reg = <&gce SUBSYS_1400XXXX 0x5000 0x1000>;
837ef62cebSEmmanuel Vadot        mediatek,gce-events = <CMDQ_EVENT_MDP_WROT0_SOF>,
847ef62cebSEmmanuel Vadot                              <CMDQ_EVENT_MDP_WROT0_EOF>;
857ef62cebSEmmanuel Vadot        power-domains = <&spm MT8183_POWER_DOMAIN_DISP>;
867ef62cebSEmmanuel Vadot        clocks = <&mmsys CLK_MM_MDP_WROT0>;
877ef62cebSEmmanuel Vadot        iommus = <&iommu>;
88*8d13bc63SEmmanuel Vadot        #dma-cells = <1>;
897ef62cebSEmmanuel Vadot    };
90