ASoC: soc-dapm: add for_each_card_widgets() macro
[sfrench/cifs-2.6.git] / sound / soc / soc-topology.c
index 575da6aba807553b87f727047dc8c41d86e3b405..33909afd3bbc158c56bb784e4c78440428ca640f 100644 (file)
@@ -2774,7 +2774,7 @@ void snd_soc_tplg_widget_remove_all(struct snd_soc_dapm_context *dapm,
 {
        struct snd_soc_dapm_widget *w, *next_w;
 
-       list_for_each_entry_safe(w, next_w, &dapm->card->widgets, list) {
+       for_each_card_widgets_safe(dapm->card, w, next_w) {
 
                /* make sure we are a widget with correct context */
                if (w->dobj.type != SND_SOC_DOBJ_WIDGET || w->dapm != dapm)