Merge remote-tracking branch 'asoc/topic/component' into asoc-next
[linux-2.6-block.git] / sound / soc / soc-dapm.c
index 177bd8639ef93e6b97a20e1cd022224e62cf14bf..79f3b1eaf3b17cf44ef82afa8c3b9229383b6687 100644 (file)
@@ -3109,7 +3109,8 @@ snd_soc_dapm_new_control(struct snd_soc_dapm_context *dapm,
        }
 
        w->dapm = dapm;
-       w->codec = dapm->codec;
+       if (dapm->component)
+               w->codec = dapm->component->codec;
        INIT_LIST_HEAD(&w->sources);
        INIT_LIST_HEAD(&w->sinks);
        INIT_LIST_HEAD(&w->list);