[alsa-devel] [RFC i-iv] ASoC: Add support for cross-device paths without dai and without name collision

Jarkko Nikula jhnikula at gmail.com
Fri Oct 29 14:00:15 CEST 2010


I'm sending here four set of patches that are build on top of another. They
are trying to solve issues with following setup:

CPU <-> [Codec x.0] -> [Codec x.1] -> out

Here only Codec x.0 has DAI link between codec and CPU, Codec x.1 is used as
an amplifier and the same codec driver is used for both codec instances.

Currently this setup is not possible because ASoC doesn't support cross-device
paths, i.e. DAPM is per codec, there is no support to register dailess codecs
and no resolution for name collisions that would occur when multiple codec
instances tries to register same kcontrols and when trying to build paths
between widgets.

I've separated patches to these problems to separate sets so that reviewing
would be easier. However, they depend on previous sets so they must be applied
sequentially and thus each set is named as RFC_[i-iv]/iv.

I've based this work on of top of Liam's DAPM decoupling patches. Those must
be squashed together but I'm sending here them separately because they include
core change from Liam and trivial conversions and minor fixes from me.

i	Decoupling DAPM from codecs. Core implementation from Liam Girdwood
	and some minor bits from me, conversion of new codecs and all the
	platforms. I've build tested the codecs and OMAP platforms and if some
	platform doesn't build, it's my fault.
ii	Extend ASoC core to handle cross-device paths. Decoupling paths and
	widgets from DAPM context and handling cross-device bias and widget
	power changes.
iii	Support for dailess codecs. This is achieved by renaming dai_link as
	dev_map, i.e. the former struct snd_soc_dai_link becomes
	struct snd_soc_dev_map so it does not only describe platform, cpu dai
	and codec binding but also registration of dailess codecs.
iv	Optional name_prefix to struct snd_soc_dev_map. With this a machine
	driver can specify a name that is used to prefix codec kcontrols,
	widgets and internal route names for avoiding name collision that would
	occur if multiple codec instances are registered.


More information about the Alsa-devel mailing list