From 17841020e9d3dbd4e8114c2142c2bc6d45c01da1 Mon Sep 17 00:00:00 2001 From: Dong Aisheng Date: Mon, 29 Aug 2011 17:15:14 +0800 Subject: 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 Tested-by: Wolfram Sang Acked-by: Liam Girdwood Signed-off-by: Mark Brown --- include/sound/soc-dai.h | 3 +++ include/sound/soc.h | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc-dai.h b/include/sound/soc-dai.h index 5ad5f3a50c68..12d98b435444 100644 --- a/include/sound/soc-dai.h +++ b/include/sound/soc-dai.h @@ -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; diff --git a/include/sound/soc.h b/include/sound/soc.h index 006f4f633c52..b499b37a6776 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -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 */ -- cgit v1.2.1