1Renesas R-Car sound
2
3Required properties:
4- compatible			: "renesas,rcar_sound-<soctype>", fallbacks
5				  "renesas,rcar_sound-gen1" if generation1, and
6				  "renesas,rcar_sound-gen2" if generation2
7				  "renesas,rcar_sound-gen3" if generation3
8				  Examples with soctypes are:
9				    - "renesas,rcar_sound-r8a7778" (R-Car M1A)
10				    - "renesas,rcar_sound-r8a7790" (R-Car H2)
11				    - "renesas,rcar_sound-r8a7791" (R-Car M2-W)
12				    - "renesas,rcar_sound-r8a7795" (R-Car H3)
13- reg				: Should contain the register physical address.
14				  required register is
15				   SRU/ADG/SSI      if generation1
16				   SRU/ADG/SSIU/SSI if generation2
17- rcar_sound,ssi		: Should contain SSI feature.
18				  The number of SSI subnode should be same as HW.
19				  see below for detail.
20- rcar_sound,src		: Should contain SRC feature.
21				  The number of SRC subnode should be same as HW.
22				  see below for detail.
23- rcar_sound,ctu		: Should contain CTU feature.
24				  The number of CTU subnode should be same as HW.
25				  see below for detail.
26- rcar_sound,mix		: Should contain MIX feature.
27				  The number of MIX subnode should be same as HW.
28				  see below for detail.
29- rcar_sound,dvc		: Should contain DVC feature.
30				  The number of DVC subnode should be same as HW.
31				  see below for detail.
32- rcar_sound,dai		: DAI contents.
33				  The number of DAI subnode should be same as HW.
34				  see below for detail.
35- #sound-dai-cells		: it must be 0 if your system is using single DAI
36				  it must be 1 if your system is using multi  DAI
37- #clock-cells			: it must be 0 if your system has audio_clkout
38				  it must be 1 if your system has audio_clkout0/1/2/3
39- clock-frequency		: for all audio_clkout0/1/2/3
40
41SSI subnode properties:
42- interrupts			: Should contain SSI interrupt for PIO transfer
43- shared-pin			: if shared clock pin
44- pio-transfer			: use PIO transfer mode
45- no-busif			: BUSIF is not ussed when [mem -> SSI] via DMA case
46- dma				: Should contain Audio DMAC entry
47- dma-names			: SSI  case "rx"  (=playback), "tx"  (=capture)
48				  SSIU case "rxu" (=playback), "txu" (=capture)
49
50SRC subnode properties:
51- dma				: Should contain Audio DMAC entry
52- dma-names			: "rx" (=playback), "tx" (=capture)
53
54DVC subnode properties:
55- dma				: Should contain Audio DMAC entry
56- dma-names			: "tx" (=playback/capture)
57
58DAI subnode properties:
59- playback			: list of playback modules
60- capture			: list of capture  modules
61
62Example:
63
64rcar_sound: sound@ec500000 {
65	#sound-dai-cells = <1>;
66	compatible = "renesas,rcar_sound-r8a7791", "renesas,rcar_sound-gen2";
67	reg =	<0 0xec500000 0 0x1000>, /* SCU */
68		<0 0xec5a0000 0 0x100>,  /* ADG */
69		<0 0xec540000 0 0x1000>, /* SSIU */
70		<0 0xec541000 0 0x1280>, /* SSI */
71		<0 0xec740000 0 0x200>;  /* Audio DMAC peri peri*/
72	reg-names = "scu", "adg", "ssiu", "ssi", "audmapp";
73
74	clocks = <&mstp10_clks R8A7790_CLK_SSI_ALL>,
75		<&mstp10_clks R8A7790_CLK_SSI9>, <&mstp10_clks R8A7790_CLK_SSI8>,
76		<&mstp10_clks R8A7790_CLK_SSI7>, <&mstp10_clks R8A7790_CLK_SSI6>,
77		<&mstp10_clks R8A7790_CLK_SSI5>, <&mstp10_clks R8A7790_CLK_SSI4>,
78		<&mstp10_clks R8A7790_CLK_SSI3>, <&mstp10_clks R8A7790_CLK_SSI2>,
79		<&mstp10_clks R8A7790_CLK_SSI1>, <&mstp10_clks R8A7790_CLK_SSI0>,
80		<&mstp10_clks R8A7790_CLK_SCU_SRC9>, <&mstp10_clks R8A7790_CLK_SCU_SRC8>,
81		<&mstp10_clks R8A7790_CLK_SCU_SRC7>, <&mstp10_clks R8A7790_CLK_SCU_SRC6>,
82		<&mstp10_clks R8A7790_CLK_SCU_SRC5>, <&mstp10_clks R8A7790_CLK_SCU_SRC4>,
83		<&mstp10_clks R8A7790_CLK_SCU_SRC3>, <&mstp10_clks R8A7790_CLK_SCU_SRC2>,
84		<&mstp10_clks R8A7790_CLK_SCU_SRC1>, <&mstp10_clks R8A7790_CLK_SCU_SRC0>,
85		<&mstp10_clks R8A7790_CLK_SCU_DVC0>, <&mstp10_clks R8A7790_CLK_SCU_DVC1>,
86		<&audio_clk_a>, <&audio_clk_b>, <&audio_clk_c>, <&m2_clk>;
87	clock-names = "ssi-all",
88			"ssi.9", "ssi.8", "ssi.7", "ssi.6", "ssi.5",
89			"ssi.4", "ssi.3", "ssi.2", "ssi.1", "ssi.0",
90			"src.9", "src.8", "src.7", "src.6", "src.5",
91			"src.4", "src.3", "src.2", "src.1", "src.0",
92			"dvc.0", "dvc.1",
93			"clk_a", "clk_b", "clk_c", "clk_i";
94
95	rcar_sound,dvc {
96		dvc0: dvc@0 {
97			dmas = <&audma0 0xbc>;
98			dma-names = "tx";
99		};
100		dvc1: dvc@1 {
101			dmas = <&audma0 0xbe>;
102			dma-names = "tx";
103		};
104	};
105
106	rcar_sound,mix {
107		mix0: mix@0 { };
108		mix1: mix@1 { };
109	};
110
111	rcar_sound,ctu {
112		ctu00: ctu@0 { };
113		ctu01: ctu@1 { };
114		ctu02: ctu@2 { };
115		ctu03: ctu@3 { };
116		ctu10: ctu@4 { };
117		ctu11: ctu@5 { };
118		ctu12: ctu@6 { };
119		ctu13: ctu@7 { };
120	};
121
122	rcar_sound,src {
123		src0: src@0 {
124			interrupts = <0 352 IRQ_TYPE_LEVEL_HIGH>;
125			dmas = <&audma0 0x85>, <&audma1 0x9a>;
126			dma-names = "rx", "tx";
127		};
128		src1: src@1 {
129			interrupts = <0 353 IRQ_TYPE_LEVEL_HIGH>;
130			dmas = <&audma0 0x87>, <&audma1 0x9c>;
131			dma-names = "rx", "tx";
132		};
133		src2: src@2 {
134			interrupts = <0 354 IRQ_TYPE_LEVEL_HIGH>;
135			dmas = <&audma0 0x89>, <&audma1 0x9e>;
136			dma-names = "rx", "tx";
137		};
138		src3: src@3 {
139			interrupts = <0 355 IRQ_TYPE_LEVEL_HIGH>;
140			dmas = <&audma0 0x8b>, <&audma1 0xa0>;
141			dma-names = "rx", "tx";
142		};
143		src4: src@4 {
144			interrupts = <0 356 IRQ_TYPE_LEVEL_HIGH>;
145			dmas = <&audma0 0x8d>, <&audma1 0xb0>;
146			dma-names = "rx", "tx";
147		};
148		src5: src@5 {
149			interrupts = <0 357 IRQ_TYPE_LEVEL_HIGH>;
150			dmas = <&audma0 0x8f>, <&audma1 0xb2>;
151			dma-names = "rx", "tx";
152		};
153		src6: src@6 {
154			interrupts = <0 358 IRQ_TYPE_LEVEL_HIGH>;
155			dmas = <&audma0 0x91>, <&audma1 0xb4>;
156			dma-names = "rx", "tx";
157		};
158		src7: src@7 {
159			interrupts = <0 359 IRQ_TYPE_LEVEL_HIGH>;
160			dmas = <&audma0 0x93>, <&audma1 0xb6>;
161			dma-names = "rx", "tx";
162		};
163		src8: src@8 {
164			interrupts = <0 360 IRQ_TYPE_LEVEL_HIGH>;
165			dmas = <&audma0 0x95>, <&audma1 0xb8>;
166			dma-names = "rx", "tx";
167		};
168		src9: src@9 {
169			interrupts = <0 361 IRQ_TYPE_LEVEL_HIGH>;
170			dmas = <&audma0 0x97>, <&audma1 0xba>;
171			dma-names = "rx", "tx";
172		};
173	};
174
175	rcar_sound,ssi {
176		ssi0: ssi@0 {
177			interrupts = <0 370 IRQ_TYPE_LEVEL_HIGH>;
178			dmas = <&audma0 0x01>, <&audma1 0x02>, <&audma0 0x15>, <&audma1 0x16>;
179			dma-names = "rx", "tx", "rxu", "txu";
180		};
181		ssi1: ssi@1 {
182			interrupts = <0 371 IRQ_TYPE_LEVEL_HIGH>;
183			dmas = <&audma0 0x03>, <&audma1 0x04>, <&audma0 0x49>, <&audma1 0x4a>;
184			dma-names = "rx", "tx", "rxu", "txu";
185		};
186		ssi2: ssi@2 {
187			interrupts = <0 372 IRQ_TYPE_LEVEL_HIGH>;
188			dmas = <&audma0 0x05>, <&audma1 0x06>, <&audma0 0x63>, <&audma1 0x64>;
189			dma-names = "rx", "tx", "rxu", "txu";
190		};
191		ssi3: ssi@3 {
192			interrupts = <0 373 IRQ_TYPE_LEVEL_HIGH>;
193			dmas = <&audma0 0x07>, <&audma1 0x08>, <&audma0 0x6f>, <&audma1 0x70>;
194			dma-names = "rx", "tx", "rxu", "txu";
195		};
196		ssi4: ssi@4 {
197			interrupts = <0 374 IRQ_TYPE_LEVEL_HIGH>;
198			dmas = <&audma0 0x09>, <&audma1 0x0a>, <&audma0 0x71>, <&audma1 0x72>;
199			dma-names = "rx", "tx", "rxu", "txu";
200		};
201		ssi5: ssi@5 {
202			interrupts = <0 375 IRQ_TYPE_LEVEL_HIGH>;
203			dmas = <&audma0 0x0b>, <&audma1 0x0c>, <&audma0 0x73>, <&audma1 0x74>;
204			dma-names = "rx", "tx", "rxu", "txu";
205		};
206		ssi6: ssi@6 {
207			interrupts = <0 376 IRQ_TYPE_LEVEL_HIGH>;
208			dmas = <&audma0 0x0d>, <&audma1 0x0e>, <&audma0 0x75>, <&audma1 0x76>;
209			dma-names = "rx", "tx", "rxu", "txu";
210		};
211		ssi7: ssi@7 {
212			interrupts = <0 377 IRQ_TYPE_LEVEL_HIGH>;
213			dmas = <&audma0 0x0f>, <&audma1 0x10>, <&audma0 0x79>, <&audma1 0x7a>;
214			dma-names = "rx", "tx", "rxu", "txu";
215		};
216		ssi8: ssi@8 {
217			interrupts = <0 378 IRQ_TYPE_LEVEL_HIGH>;
218			dmas = <&audma0 0x11>, <&audma1 0x12>, <&audma0 0x7b>, <&audma1 0x7c>;
219			dma-names = "rx", "tx", "rxu", "txu";
220		};
221		ssi9: ssi@9 {
222			interrupts = <0 379 IRQ_TYPE_LEVEL_HIGH>;
223			dmas = <&audma0 0x13>, <&audma1 0x14>, <&audma0 0x7d>, <&audma1 0x7e>;
224			dma-names = "rx", "tx", "rxu", "txu";
225		};
226	};
227
228	rcar_sound,dai {
229		dai0 {
230			playback = <&ssi5 &src5>;
231			capture  = <&ssi6>;
232		};
233		dai1 {
234			playback = <&ssi3>;
235		};
236		dai2 {
237			capture  = <&ssi4>;
238		};
239		dai3 {
240			playback = <&ssi7>;
241		};
242		dai4 {
243			capture  = <&ssi8>;
244		};
245	};
246};
247