1# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2
3%YAML 1.2
4---
5$id: "http://devicetree.org/schemas/media/qcom,sc7180-venus.yaml#"
6$schema: "http://devicetree.org/meta-schemas/core.yaml#"
7
8title: Qualcomm Venus video encode and decode accelerators
9
10maintainers:
11  - Stanimir Varbanov <stanimir.varbanov@linaro.org>
12
13description: |
14  The Venus IP is a video encode and decode accelerator present
15  on Qualcomm platforms
16
17properties:
18  compatible:
19    const: qcom,sc7180-venus
20
21  reg:
22    maxItems: 1
23
24  interrupts:
25    maxItems: 1
26
27  power-domains:
28    maxItems: 2
29
30  power-domain-names:
31    items:
32      - const: venus
33      - const: vcodec0
34
35  clocks:
36    maxItems: 5
37
38  clock-names:
39    items:
40      - const: core
41      - const: iface
42      - const: bus
43      - const: vcodec0_core
44      - const: vcodec0_bus
45
46  iommus:
47    maxItems: 1
48
49  memory-region:
50    maxItems: 1
51
52  interconnects:
53    maxItems: 2
54
55  interconnect-names:
56    items:
57      - const: video-mem
58      - const: cpu-cfg
59
60  video-decoder:
61    type: object
62
63    properties:
64      compatible:
65        const: venus-decoder
66
67    required:
68      - compatible
69
70    additionalProperties: false
71
72  video-encoder:
73    type: object
74
75    properties:
76      compatible:
77        const: venus-encoder
78
79    required:
80      - compatible
81
82    additionalProperties: false
83
84  video-firmware:
85    type: object
86
87    description: |
88      Firmware subnode is needed when the platform does not
89      have TrustZone.
90
91    properties:
92      iommus:
93        maxItems: 1
94
95    required:
96      - iommus
97
98required:
99  - compatible
100  - reg
101  - interrupts
102  - power-domains
103  - power-domain-names
104  - clocks
105  - clock-names
106  - iommus
107  - memory-region
108  - video-decoder
109  - video-encoder
110
111additionalProperties: false
112
113examples:
114  - |
115        #include <dt-bindings/interrupt-controller/arm-gic.h>
116        #include <dt-bindings/clock/qcom,videocc-sc7180.h>
117
118        venus: video-codec@aa00000 {
119                compatible = "qcom,sc7180-venus";
120                reg = <0x0aa00000 0xff000>;
121                interrupts = <GIC_SPI 174 IRQ_TYPE_LEVEL_HIGH>;
122                power-domains = <&videocc VENUS_GDSC>,
123                                <&videocc VCODEC0_GDSC>;
124                power-domain-names = "venus", "vcodec0";
125                clocks = <&videocc VIDEO_CC_VENUS_CTL_CORE_CLK>,
126                         <&videocc VIDEO_CC_VENUS_AHB_CLK>,
127                         <&videocc VIDEO_CC_VENUS_CTL_AXI_CLK>,
128                         <&videocc VIDEO_CC_VCODEC0_CORE_CLK>,
129                         <&videocc VIDEO_CC_VCODEC0_AXI_CLK>;
130                clock-names = "core", "iface", "bus",
131                              "vcodec0_core", "vcodec0_bus";
132                iommus = <&apps_smmu 0x0c00 0x60>;
133                memory-region = <&venus_mem>;
134
135                video-decoder {
136                        compatible = "venus-decoder";
137                };
138
139                video-encoder {
140                        compatible = "venus-encoder";
141                };
142        };
143