Question about OF-graph ports
From: Kuninori Morimoto <hidden>
Date: 2017-01-19 06:07:43
Also in:
alsa-devel
Hi Rob, Mark
and ALSA SoC ML
I'm working for OF-graph base sound card support.
Now I want to know 1 things which can't solve by myself.
It is OF-graph ports
ALSA SoC needs CPU, Codec, and Sound Card.
If CPU <-> Card <-> Codec case, OF-graph will be
card {
ports {
port@0 {
card_in: endpoint {
remote-endpoint = <&cpu_out>;
};
};
port@1 {
card_out: endpoint {
remote-endpoint = <&codec_in>;
};
};
};
};
cpu {
port {
cpu_out: endpoint {
remote-endpoint = <&card_in>;
};
};
};
codec {
port {
codec_in: endpoint {
remote-endpoint = <&card_out>;
};
};
};
This is OK.
If CPU has many ports, then ALSA SoC requests 1 Card which has many
DAIs (= Digital Audio Interface).
This case, cpu will have "ports" and many "port", this is OK.
SoC.0 Codec0
SoC.1 <-> Card <-> Codec1
SoC.2 Codec2
In "card", CPU/Codec pair is indicated by "ports" now
(= port0 is CPU, port1 is Codec, etc)
My question is in this case, how to know CPU/Codec pair on "card" ?
Can we have *multi ports*, like this ?
card {
ports {
ports@0 {
port@0 { /* SoC.0 */ };
port@1 { /* Codec0*/ };
};
ports@1 {
port@0 { /* SoC.1 */ };
port@1 { /* Codec1*/ };
};
ports@2 {
port@0 { /* SoC.2 */ };
port@1 { /* Codec2*/ };
};
};
};
Or can I use grouping, like this ?
card {
group = <port@0 port@1>,
<port@2 port@3>,
<port@4 port@5>;
ports {
port@0 { /* SoC.0 */ };
port@1 { /* SoC.1 */ };
port@2 { /* SoC.2 */ };
port@3 { /* Codec0*/ };
port@4 { /* Codec1*/ };
port@5 { /* Codec2*/ };
};
};
Best regards
---
Kuninori Morimoto
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html