ASoC: Fix CODEC enumeration for auto_nc_codec_pins
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Sun, 27 Nov 2011 19:38:34 +0000 (19:38 +0000)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Sun, 27 Nov 2011 19:45:36 +0000 (19:45 +0000)
We need to enumerate all the CODECs that are part of the card we're
instantiating, not all the CODECs that are in the system as the system
may have multiple cards.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/soc-core.c

index 2abaf6dcdb0ac06b750231982bf3c06e665b875d..ec783f0a27e9d00925ceb494c1864aa34c4b2ff9 100644 (file)
@@ -1489,7 +1489,7 @@ static void snd_soc_instantiate_card(struct snd_soc_card *card)
        snd_soc_dapm_new_widgets(&card->dapm);
 
        if (card->fully_routed)
-               list_for_each_entry(codec, &codec_list, list)
+               list_for_each_entry(codec, &card->codec_dev_list, card_list)
                        snd_soc_dapm_auto_nc_codec_pins(codec);
 
        ret = snd_card_register(card->snd_card);