aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/soc-pcm.c
diff options
context:
space:
mode:
authorMark Brown <broonie@linaro.org>2013-06-05 14:36:11 -0400
committerMark Brown <broonie@linaro.org>2013-06-07 10:54:50 -0400
commit4616274d3382fa7698536d61b351e63cf0ce27f0 (patch)
tree8e95ffc206ad5f33eacfd19539e4ba0b16b48f25 /sound/soc/soc-pcm.c
parent056790923e1c4eed5d8cc502e1092944a2b23025 (diff)
ASoC: dapm: Treat DAI widgets like AIF widgets for power
Even though they are virtual widgets DAI widgets still get counted for the DAPM context power management so we can't just use the active state to check if they should be powered as they may not be part of a complete path. Instead split them into input and output widgets and do the same power checks as we perform on AIFs. Reported-by: Stephen Warren <swarren@nvidia.com> Tested-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'sound/soc/soc-pcm.c')
-rw-r--r--sound/soc/soc-pcm.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c
index a9fddf0fea19..ccb6be4d658d 100644
--- a/sound/soc/soc-pcm.c
+++ b/sound/soc/soc-pcm.c
@@ -928,8 +928,13 @@ static int dpcm_add_paths(struct snd_soc_pcm_runtime *fe, int stream,
928 /* Create any new FE <--> BE connections */ 928 /* Create any new FE <--> BE connections */
929 for (i = 0; i < list->num_widgets; i++) { 929 for (i = 0; i < list->num_widgets; i++) {
930 930
931 if (list->widgets[i]->id != snd_soc_dapm_dai) 931 switch (list->widgets[i]->id) {
932 case snd_soc_dapm_dai_in:
933 case snd_soc_dapm_dai_out:
934 break;
935 default:
932 continue; 936 continue;
937 }
933 938
934 /* is there a valid BE rtd for this widget */ 939 /* is there a valid BE rtd for this widget */
935 be = dpcm_get_be(card, list->widgets[i], stream); 940 be = dpcm_get_be(card, list->widgets[i], stream);