[alsa-devel] simle-card DT style for DPCM
Kuninori Morimoto
kuninori.morimoto.gx at gmail.com
Tue Sep 2 03:28:04 CEST 2014
Hi Mark
> I think here what I'd expect to see is only one CPU DAI specified for
> the back end link in the CPU that is actually linked to the CODEC and
> the front ends being worked out by the drivers, unless there are systems
> where the set of front ends can be configured at system build time (as
> opposed to from software at runtime) somehow.
This means BE don't know who is FE.
The implementation can be more easy if it has
connect-to / connect-from property
(I'm not sure this is good naming...)
So, how about this ?
In pattern 3 case, it can be FE/BE if connect-to / connect-from was added,
otherwise, it will be normal DAI link.
connect-to / connect-from can be used if FE/BE were implemented
in different driver (pattern 3 indicates simle-card is BE)
We use pattern2 if FE/BE was not separated.
---------------------------------------
pattern 1: use DPCM in simple-card
---------------------------------------
It is supported, but it should use pattern 2 case.
This is sample of connect-to / connect-from.
see pattern 3
sound {
compatible = "simple-audio-card";
...
/* Front End */
dai_link0: simple-audio-card,dai-link at 0 {
...
connect-to = <&dai-link1>;
cpu { ... };
codec { ... };
}
/* Back End */
dai_link1: simple-audio-card,dai-link at 1 {
...
connect-from = <&dai-link0>;
cpu { ... };
codec { ... };
}
}
---------------------------------------
pattern 2: use DPCM in 1 simple-card
---------------------------------------
sound {
compatible = "simple-audio-card";
...
simple-audio-card,dai-link {
...
cpu at 0 { ... }; /* FE-cpu *//* FE-codec is dummy */
cpu at 1 { ... }; /* BE-cpu */
codec at 1 { ... }; /* BE-codec */
}
}
---------------------------------------
pattern 3: use DPCM in simple-card and other driver
---------------------------------------
sound {
compatible = "simple-audio-card";
...
dai_link: simple-audio-card,dai-link {
...
cpu { ... };
codec { ... };
}
}
--
foo-bar-link: foo-bar-sound {
compatible = "foo-bar-sound";
...
remote = <&dai-link>; /* foo-bar style FE
* same as "connect-to" in simple-card
*/
};
&dai_link {
/* Back End */
connect-from = <&foo-bar-link>;
};
Best regards
---
Kuninori Morimoto
More information about the Alsa-devel
mailing list