GNU Linux-libre 6.1.90-gnu
[releases.git] / Documentation / devicetree / bindings / sound / amlogic,aiu.yaml
1 # SPDX-License-Identifier: GPL-2.0
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/sound/amlogic,aiu.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: Amlogic AIU audio output controller
8
9 maintainers:
10   - Jerome Brunet <jbrunet@baylibre.com>
11
12 allOf:
13   - $ref: name-prefix.yaml#
14
15 properties:
16   $nodename:
17     pattern: "^audio-controller@.*"
18
19   "#sound-dai-cells":
20     const: 2
21
22   compatible:
23     items:
24       - enum:
25           - amlogic,aiu-gxbb
26           - amlogic,aiu-gxl
27           - amlogic,aiu-meson8
28           - amlogic,aiu-meson8b
29       - const: amlogic,aiu
30
31   clocks:
32     items:
33       - description: AIU peripheral clock
34       - description: I2S peripheral clock
35       - description: I2S output clock
36       - description: I2S master clock
37       - description: I2S mixer clock
38       - description: SPDIF peripheral clock
39       - description: SPDIF output clock
40       - description: SPDIF master clock
41       - description: SPDIF master clock multiplexer
42
43   clock-names:
44     items:
45       - const: pclk
46       - const: i2s_pclk
47       - const: i2s_aoclk
48       - const: i2s_mclk
49       - const: i2s_mixer
50       - const: spdif_pclk
51       - const: spdif_aoclk
52       - const: spdif_mclk
53       - const: spdif_mclk_sel
54
55   interrupts:
56     items:
57       - description: I2S interrupt line
58       - description: SPDIF interrupt line
59
60   interrupt-names:
61     items:
62       - const: i2s
63       - const: spdif
64
65   reg:
66     maxItems: 1
67
68   resets:
69     maxItems: 1
70
71   sound-name-prefix: true
72
73 required:
74   - "#sound-dai-cells"
75   - compatible
76   - clocks
77   - clock-names
78   - interrupts
79   - interrupt-names
80   - reg
81   - resets
82
83 additionalProperties: false
84
85 examples:
86   - |
87     #include <dt-bindings/clock/gxbb-clkc.h>
88     #include <dt-bindings/interrupt-controller/irq.h>
89     #include <dt-bindings/interrupt-controller/arm-gic.h>
90     #include <dt-bindings/reset/amlogic,meson-gxbb-reset.h>
91
92     aiu: audio-controller@5400 {
93         compatible = "amlogic,aiu-gxl", "amlogic,aiu";
94         #sound-dai-cells = <2>;
95         reg = <0x5400 0x2ac>;
96         interrupts = <GIC_SPI 48 IRQ_TYPE_EDGE_RISING>,
97                      <GIC_SPI 50 IRQ_TYPE_EDGE_RISING>;
98         interrupt-names = "i2s", "spdif";
99         clocks = <&clkc CLKID_AIU_GLUE>,
100                  <&clkc CLKID_I2S_OUT>,
101                  <&clkc CLKID_AOCLK_GATE>,
102                  <&clkc CLKID_CTS_AMCLK>,
103                  <&clkc CLKID_MIXER_IFACE>,
104                  <&clkc CLKID_IEC958>,
105                  <&clkc CLKID_IEC958_GATE>,
106                  <&clkc CLKID_CTS_MCLK_I958>,
107                  <&clkc CLKID_CTS_I958>;
108         clock-names = "pclk",
109                       "i2s_pclk",
110                       "i2s_aoclk",
111                       "i2s_mclk",
112                       "i2s_mixer",
113                       "spdif_pclk",
114                       "spdif_aoclk",
115                       "spdif_mclk",
116                       "spdif_mclk_sel";
117         resets = <&reset RESET_AIU>;
118     };