aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorLiam Girdwood <lrg@ti.com>2012-04-17 13:00:11 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-04-17 15:52:19 -0400
commita7dbb603423d499acacefb5fad65d2b406f16370 (patch)
tree86e84e818848fe637e6fb494ba118cc48019fb2a /sound
parent86fc49982369f6918dd9c6eeb70b38ab2303ed0a (diff)
ASoC: core: Fix card RTD count for deferred probe.
Currently we increment the number of RTD's per card during the DAI link bind. This can cause an incorrect RTD count when we cannot find a component and defer the probe (and hence perform the DAI link bind for the card again). Fix the count so that it is cleared before every card registration and bind attempt. Signed-off-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/soc-core.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c
index 8d2ebf502df4..3a4e93e52b6d 100644
--- a/sound/soc/soc-core.c
+++ b/sound/soc/soc-core.c
@@ -3119,6 +3119,7 @@ int snd_soc_register_card(struct snd_soc_card *card)
3119 GFP_KERNEL); 3119 GFP_KERNEL);
3120 if (card->rtd == NULL) 3120 if (card->rtd == NULL)
3121 return -ENOMEM; 3121 return -ENOMEM;
3122 card->num_rtd = 0;
3122 card->rtd_aux = &card->rtd[card->num_links]; 3123 card->rtd_aux = &card->rtd[card->num_links];
3123 3124
3124 for (i = 0; i < card->num_links; i++) 3125 for (i = 0; i < card->num_links; i++)