ASoC: audio-graph-card2: expand dai_link property part
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Tue, 28 May 2024 05:05:28 +0000 (05:05 +0000)
committerMark Brown <broonie@kernel.org>
Mon, 3 Jun 2024 14:59:36 +0000 (15:59 +0100)
commit844de7eebe97a1c277f8a408457712086c957195
tree6994569ac38d49577e5b0cf85923dcecd5ce141d
parent33ae57277ce08b83c65c18a09bf09499de613c01
ASoC: audio-graph-card2: expand dai_link property part

Current dai_link related property are parsed and enabled only on CPU
port node (A)(b)(c). OTOH, Audio Graph Card2 supports many connections
like Multi-CPU, DPCM, Codec2Codec today. For example in Multi-CPU case,
it will be checked via (X) -> (B) -> (b) process, but (X) / (B) part
property is not parsed.

>From dai_link related settings point of view, (B) (C) part and Codec
port also enabled is more viscerally understandable, and useful.

card2 {
(X) links = <&snd-cpu (A)
 &snd-multi (B)
 &snd-dpcm (C)
 ...>

multi {
ports {
(B) snd-multi: port { ... };
...
};
};
dpcm {
ports {
(C) snd-dpcm: port { ... };
...
};
};
codec2codec {
...
};
};

cpu_device {
ports {
(A) snd-cpu: port { ... };
(b) mcpu:    port { ... };
(c) dcpu:    port { ... };
}
};

One note here is that if it was Multi-CPU/Codec case, 1st port only
enabled to have property it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://msgid.link/r/875xuyh6g7.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/generic/audio-graph-card2.c
sound/soc/generic/simple-card-utils.c