xref: /freebsd/sys/contrib/device-tree/src/arm64/renesas/ulcb-kf-audio-graph-card-mix+split.dtsi (revision 84943d6f38e936ac3b7a3947ca26eeb27a39f938)
1cb7aa33aSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0
2cb7aa33aSEmmanuel Vadot/*
3cb7aa33aSEmmanuel Vadot * Device Tree for ULCB + Kingfisher + Audio Graph Card (MIX + TDM Split)
4cb7aa33aSEmmanuel Vadot *
5cb7aa33aSEmmanuel Vadot * Copyright (C) 2022 Renesas Electronics Corp.
6cb7aa33aSEmmanuel Vadot */
7cb7aa33aSEmmanuel Vadot
8cb7aa33aSEmmanuel Vadot/*
9cb7aa33aSEmmanuel Vadot * Note:
10cb7aa33aSEmmanuel Vadot * The HDMI output is ignored due to the limited number of subdevices
11cb7aa33aSEmmanuel Vadot *
12cb7aa33aSEmmanuel Vadot *	(A) CPU0 (2ch) <----> (2ch) (X) ak4613	   (MIX-0)
13cb7aa33aSEmmanuel Vadot *	(B) CPU1 (2ch)  --/			   (MIX-1)
14cb7aa33aSEmmanuel Vadot *	(C) CPU2 (2ch)  ----> (8ch) (Y) PCM3168A-p (TDM-0 : 0,1ch)
15cb7aa33aSEmmanuel Vadot *	(D) CPU3 (2ch)  --/			   (TDM-1 : 2,3ch)
16cb7aa33aSEmmanuel Vadot *	(E) CPU4 (2ch)  --/			   (TDM-2 : 4,5ch)
17cb7aa33aSEmmanuel Vadot *	(F) CPU5 (2ch)  --/			   (TDM-3 : 6,7ch)
18cb7aa33aSEmmanuel Vadot *	(G) CPU6 (6ch) <----  (6ch) (Z) PCM3168A-c
19cb7aa33aSEmmanuel Vadot *
20cb7aa33aSEmmanuel Vadot *	(A) aplay   -D plughw:0,0 xxx.wav (MIX-0)
21cb7aa33aSEmmanuel Vadot *	(B) aplay   -D plughw:0,1 xxx.wav (MIX-1)
22*84943d6fSEmmanuel Vadot *	(C) aplay   -D plughw:1,0 xxx.wav (TDM-0)
23*84943d6fSEmmanuel Vadot *	(D) aplay   -D plughw:1,1 xxx.wav (TDM-1)
24*84943d6fSEmmanuel Vadot *	(E) aplay   -D plughw:1,2 xxx.wav (TDM-2)
25*84943d6fSEmmanuel Vadot *	(F) aplay   -D plughw:1,3 xxx.wav (TDM-3)
26cb7aa33aSEmmanuel Vadot *
27cb7aa33aSEmmanuel Vadot *	(A) arecord -D plughw:0,0 xxx.wav
28*84943d6fSEmmanuel Vadot *	(G) arecord -D plughw:1,4 xxx.wav
29cb7aa33aSEmmanuel Vadot */
30*84943d6fSEmmanuel Vadot/ {
31*84943d6fSEmmanuel Vadot	sound_card_kf: expand-sound {
32*84943d6fSEmmanuel Vadot		compatible = "audio-graph-scu-card";
33*84943d6fSEmmanuel Vadot		label = "snd-kf-split";
34cb7aa33aSEmmanuel Vadot
35*84943d6fSEmmanuel Vadot		routing = "pcm3168a Playback", "DAI2 Playback",
36cb7aa33aSEmmanuel Vadot			  "pcm3168a Playback", "DAI3 Playback",
37cb7aa33aSEmmanuel Vadot			  "pcm3168a Playback", "DAI4 Playback",
38cb7aa33aSEmmanuel Vadot			  "pcm3168a Playback", "DAI5 Playback";
39cb7aa33aSEmmanuel Vadot
40*84943d6fSEmmanuel Vadot		dais = <&snd_kf1 /* (C) CPU2 */
41*84943d6fSEmmanuel Vadot			&snd_kf2 /* (D) CPU3 */
42*84943d6fSEmmanuel Vadot			&snd_kf3 /* (E) CPU4 */
43*84943d6fSEmmanuel Vadot			&snd_kf4 /* (F) CPU5 */
44*84943d6fSEmmanuel Vadot			&snd_kf5 /* (G) GPU6 */
45cb7aa33aSEmmanuel Vadot		>;
46cb7aa33aSEmmanuel Vadot	};
47*84943d6fSEmmanuel Vadot};
48cb7aa33aSEmmanuel Vadot
49cb7aa33aSEmmanuel Vadot&pcm3168a {
50cb7aa33aSEmmanuel Vadot	ports {
51cb7aa33aSEmmanuel Vadot		#address-cells = <1>;
52cb7aa33aSEmmanuel Vadot		#size-cells = <0>;
53cb7aa33aSEmmanuel Vadot		mclk-fs = <512>;
54cb7aa33aSEmmanuel Vadot
55cb7aa33aSEmmanuel Vadot		/*
56cb7aa33aSEmmanuel Vadot		 * (Y) PCM3168A-p
57cb7aa33aSEmmanuel Vadot		 */
58cb7aa33aSEmmanuel Vadot		port@0 {
59cb7aa33aSEmmanuel Vadot			#address-cells = <1>;
60cb7aa33aSEmmanuel Vadot			#size-cells = <0>;
61cb7aa33aSEmmanuel Vadot			reg = <0>;
62cb7aa33aSEmmanuel Vadot			prefix = "pcm3168a";
63cb7aa33aSEmmanuel Vadot			convert-channels = <8>; /* to 8ch TDM */
64cb7aa33aSEmmanuel Vadot
65cb7aa33aSEmmanuel Vadot			/* (C) CPU2 -> (Y) PCM3168A-p */
66cb7aa33aSEmmanuel Vadot			pcm3168a_endpoint_p1: endpoint@0 {
67cb7aa33aSEmmanuel Vadot				reg = <0>;
68cb7aa33aSEmmanuel Vadot				remote-endpoint = <&rsnd_for_pcm3168a_play1>;
69cb7aa33aSEmmanuel Vadot				clocks = <&clksndsel>;
70cb7aa33aSEmmanuel Vadot			};
71cb7aa33aSEmmanuel Vadot			/* (D) CPU3 -> (Y) PCM3168A-p */
72cb7aa33aSEmmanuel Vadot			pcm3168a_endpoint_p2: endpoint@1 {
73cb7aa33aSEmmanuel Vadot				reg = <1>;
74cb7aa33aSEmmanuel Vadot				remote-endpoint = <&rsnd_for_pcm3168a_play2>;
75cb7aa33aSEmmanuel Vadot				clocks = <&clksndsel>;
76cb7aa33aSEmmanuel Vadot			};
77cb7aa33aSEmmanuel Vadot			/* (E) CPU4 -> (Y) PCM3168A-p */
78cb7aa33aSEmmanuel Vadot			pcm3168a_endpoint_p3: endpoint@2 {
79cb7aa33aSEmmanuel Vadot				reg = <2>;
80cb7aa33aSEmmanuel Vadot				remote-endpoint = <&rsnd_for_pcm3168a_play3>;
81cb7aa33aSEmmanuel Vadot				clocks = <&clksndsel>;
82cb7aa33aSEmmanuel Vadot			};
83cb7aa33aSEmmanuel Vadot			/* (F) CPU5 -> (Y) PCM3168A-p */
84cb7aa33aSEmmanuel Vadot			pcm3168a_endpoint_p4: endpoint@3 {
85cb7aa33aSEmmanuel Vadot				reg = <3>;
86cb7aa33aSEmmanuel Vadot				remote-endpoint = <&rsnd_for_pcm3168a_play4>;
87cb7aa33aSEmmanuel Vadot				clocks = <&clksndsel>;
88cb7aa33aSEmmanuel Vadot			};
89cb7aa33aSEmmanuel Vadot		};
90cb7aa33aSEmmanuel Vadot		/*
91cb7aa33aSEmmanuel Vadot		 * (Z) PCM3168A-c
92cb7aa33aSEmmanuel Vadot		 */
93cb7aa33aSEmmanuel Vadot		port@1 {
94cb7aa33aSEmmanuel Vadot			reg = <1>;
95cb7aa33aSEmmanuel Vadot			/* (G) CPU6 <- PCM3168A-c */
96cb7aa33aSEmmanuel Vadot			pcm3168a_endpoint_c: endpoint {
97cb7aa33aSEmmanuel Vadot				remote-endpoint = <&rsnd_for_pcm3168a_capture>;
98cb7aa33aSEmmanuel Vadot				clocks = <&clksndsel>;
99cb7aa33aSEmmanuel Vadot			};
100cb7aa33aSEmmanuel Vadot		};
101cb7aa33aSEmmanuel Vadot	};
102cb7aa33aSEmmanuel Vadot};
103cb7aa33aSEmmanuel Vadot
104cb7aa33aSEmmanuel Vadot&rcar_sound {
105*84943d6fSEmmanuel Vadot	ports@1 {
106*84943d6fSEmmanuel Vadot		#address-cells = <1>;
107*84943d6fSEmmanuel Vadot		#size-cells = <0>;
108*84943d6fSEmmanuel Vadot		reg = <1>;
109cb7aa33aSEmmanuel Vadot
110cb7aa33aSEmmanuel Vadot		/*
111cb7aa33aSEmmanuel Vadot		 * (C) CPU2
112cb7aa33aSEmmanuel Vadot		 */
113*84943d6fSEmmanuel Vadot		snd_kf1: port@2 {
114cb7aa33aSEmmanuel Vadot			reg = <2>;
115cb7aa33aSEmmanuel Vadot			rsnd_for_pcm3168a_play1: endpoint {
116cb7aa33aSEmmanuel Vadot				remote-endpoint = <&pcm3168a_endpoint_p1>;
117cb7aa33aSEmmanuel Vadot				bitclock-master;
118cb7aa33aSEmmanuel Vadot				frame-master;
119cb7aa33aSEmmanuel Vadot				playback = <&ssiu30 &ssi3>;
120cb7aa33aSEmmanuel Vadot			};
121cb7aa33aSEmmanuel Vadot		};
122cb7aa33aSEmmanuel Vadot		/*
123cb7aa33aSEmmanuel Vadot		 * (D) CPU3
124cb7aa33aSEmmanuel Vadot		 */
125*84943d6fSEmmanuel Vadot		snd_kf2: port@3 {
126cb7aa33aSEmmanuel Vadot			reg = <3>;
127cb7aa33aSEmmanuel Vadot			rsnd_for_pcm3168a_play2: endpoint {
128cb7aa33aSEmmanuel Vadot				remote-endpoint = <&pcm3168a_endpoint_p2>;
129cb7aa33aSEmmanuel Vadot				bitclock-master;
130cb7aa33aSEmmanuel Vadot				frame-master;
131cb7aa33aSEmmanuel Vadot				playback = <&ssiu31 &ssi3>;
132cb7aa33aSEmmanuel Vadot			};
133cb7aa33aSEmmanuel Vadot		};
134cb7aa33aSEmmanuel Vadot		/*
135cb7aa33aSEmmanuel Vadot		 * (E) CPU4
136cb7aa33aSEmmanuel Vadot		 */
137*84943d6fSEmmanuel Vadot		snd_kf3: port@4 {
138cb7aa33aSEmmanuel Vadot			reg = <4>;
139cb7aa33aSEmmanuel Vadot			rsnd_for_pcm3168a_play3: endpoint {
140cb7aa33aSEmmanuel Vadot				remote-endpoint = <&pcm3168a_endpoint_p3>;
141cb7aa33aSEmmanuel Vadot				bitclock-master;
142cb7aa33aSEmmanuel Vadot				frame-master;
143cb7aa33aSEmmanuel Vadot				playback = <&ssiu32 &ssi3>;
144cb7aa33aSEmmanuel Vadot			};
145cb7aa33aSEmmanuel Vadot		};
146cb7aa33aSEmmanuel Vadot		/*
147cb7aa33aSEmmanuel Vadot		 * (F) CPU5
148cb7aa33aSEmmanuel Vadot		 */
149*84943d6fSEmmanuel Vadot		snd_kf4: port@5 {
150cb7aa33aSEmmanuel Vadot			reg = <5>;
151cb7aa33aSEmmanuel Vadot			rsnd_for_pcm3168a_play4: endpoint {
152cb7aa33aSEmmanuel Vadot				remote-endpoint = <&pcm3168a_endpoint_p4>;
153cb7aa33aSEmmanuel Vadot				bitclock-master;
154cb7aa33aSEmmanuel Vadot				frame-master;
155cb7aa33aSEmmanuel Vadot				playback = <&ssiu33 &ssi3>;
156cb7aa33aSEmmanuel Vadot			};
157cb7aa33aSEmmanuel Vadot		};
158cb7aa33aSEmmanuel Vadot		/*
159cb7aa33aSEmmanuel Vadot		 * (G) CPU6
160cb7aa33aSEmmanuel Vadot		 */
161*84943d6fSEmmanuel Vadot		snd_kf5: port@6 {
162cb7aa33aSEmmanuel Vadot			reg = <6>;
163cb7aa33aSEmmanuel Vadot			rsnd_for_pcm3168a_capture: endpoint {
164cb7aa33aSEmmanuel Vadot				remote-endpoint = <&pcm3168a_endpoint_c>;
165cb7aa33aSEmmanuel Vadot				bitclock-master;
166cb7aa33aSEmmanuel Vadot				frame-master;
167cb7aa33aSEmmanuel Vadot				dai-tdm-slot-num = <6>;
168cb7aa33aSEmmanuel Vadot				capture  = <&ssi4>;
169cb7aa33aSEmmanuel Vadot			};
170cb7aa33aSEmmanuel Vadot		};
171cb7aa33aSEmmanuel Vadot	};
172cb7aa33aSEmmanuel Vadot};
173