ASoC: soc-core: symmetry checking for each DAIs separately

The orginal code does not cover the case that one DAI such as codec
may be shared between other two DAIs(CPU).
When do symmetry checking, altough the codec DAI requires symmetry,
the two CPU DAIs may still be configured to run on different rates.

We change to check each DAI's state separately instead of only checking
the dai link to prevent this issue.

Signed-off-by: Dong Aisheng <b29396@freescale.com>
Tested-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This commit is contained in:
Dong Aisheng
2011-08-29 17:15:14 +08:00
committed by Mark Brown
parent 548aae8cc4
commit 17841020e9
3 changed files with 28 additions and 17 deletions

View File

@@ -242,6 +242,9 @@ struct snd_soc_dai {
void *playback_dma_data;
void *capture_dma_data;
/* Symmetry data - only valid if symmetry is being enforced */
unsigned int rate;
/* parent platform/codec */
union {
struct snd_soc_platform *platform;

View File

@@ -851,8 +851,6 @@ struct snd_soc_pcm_runtime {
unsigned int complete:1;
unsigned int dev_registered:1;
/* Symmetry data - only valid if symmetry is being enforced */
unsigned int rate;
long pmdown_time;
/* runtime devices */