};
 
 /* Corgi machine audio map (connections to the codec pins) */
-static const char *audio_map[][3] = {
+static const struct snd_soc_dapm_route audio_map[] = {
 
        /* headset Jack  - in = micin, out = LHPOUT*/
        {"Headset Jack", NULL, "LHPOUT"},
 
        /* Same as the above but no mic bias for line signals */
        {"MICIN", NULL, "Line Jack"},
-
-       {NULL, NULL, NULL},
 };
 
 static const char *jack_function[] = {"Headphone", "Mic", "Line", "Headset",
        }
 
        /* Add corgi specific widgets */
-       for (i = 0; i < ARRAY_SIZE(wm8731_dapm_widgets); i++)
-               snd_soc_dapm_new_control(codec, &wm8731_dapm_widgets[i]);
+       snd_soc_dapm_new_controls(codec, wm8731_dapm_widgets,
+                                 ARRAY_SIZE(wm8731_dapm_widgets));
 
        /* Set up corgi specific audio path audio_map */
-       for (i = 0; audio_map[i][0] != NULL; i++)
-               snd_soc_dapm_connect_input(codec, audio_map[i][0],
-                       audio_map[i][1], audio_map[i][2]);
+       snd_soc_dapm_add_routes(codec, audio_map, ARRAY_SIZE(audio_map));
 
        snd_soc_dapm_sync_endpoints(codec);
        return 0;
 
 SND_SOC_DAPM_SPK("Ext Spk", poodle_amp_event),
 };
 
-/* Corgi machine audio_mapnections to the codec pins */
-static const char *audio_map[][3] = {
+/* Corgi machine connections to the codec pins */
+static const struct snd_soc_dapm_route audio_map[] = {
 
        /* headphone connected to LHPOUT1, RHPOUT1 */
        {"Headphone Jack", NULL, "LHPOUT"},
        /* speaker connected to LOUT, ROUT */
        {"Ext Spk", NULL, "ROUT"},
        {"Ext Spk", NULL, "LOUT"},
-
-       {NULL, NULL, NULL},
 };
 
 static const char *jack_function[] = {"Off", "Headphone"};
        }
 
        /* Add poodle specific widgets */
-       for (i = 0; i < ARRAY_SIZE(wm8731_dapm_widgets); i++)
-               snd_soc_dapm_new_control(codec, &wm8731_dapm_widgets[i]);
+       snd_soc_dapm_new_controls(codec, wm8731_dapm_widgets,
+                                 ARRAY_SIZE(wm8731_dapm_widgets));
 
        /* Set up poodle specific audio path audio_map */
-       for (i = 0; audio_map[i][0] != NULL; i++)
-               snd_soc_dapm_connect_input(codec, audio_map[i][0],
-                       audio_map[i][1], audio_map[i][2]);
+       snd_soc_dapm_add_routes(codec, audio_map, ARRAY_SIZE(audio_map));
 
        snd_soc_dapm_sync_endpoints(codec);
        return 0;
 
 };
 
 /* Spitz machine audio_map */
-static const char *audio_map[][3] = {
+static const struct snd_soc_dapm_route audio_map[] = {
 
        /* headphone connected to LOUT1, ROUT1 */
        {"Headphone Jack", NULL, "LOUT1"},
 
        /* line is connected to input 1 - no bias */
        {"LINPUT1", NULL, "Line Jack"},
-
-       {NULL, NULL, NULL},
 };
 
 static const char *jack_function[] = {"Headphone", "Mic", "Line", "Headset",
        }
 
        /* Add spitz specific widgets */
-       for (i = 0; i < ARRAY_SIZE(wm8750_dapm_widgets); i++)
-               snd_soc_dapm_new_control(codec, &wm8750_dapm_widgets[i]);
+       snd_soc_dapm_new_controls(codec, wm8750_dapm_widgets,
+                                 ARRAY_SIZE(wm8750_dapm_widgets));
 
-       /* Set up spitz specific audio path audio_map */
-       for (i = 0; audio_map[i][0] != NULL; i++)
-               snd_soc_dapm_connect_input(codec, audio_map[i][0],
-                       audio_map[i][1], audio_map[i][2]);
+       /* Set up spitz specific audio paths */
+       snd_soc_dapm_add_routes(codec, audio_map, ARRAY_SIZE(audio_map));
 
        snd_soc_dapm_sync_endpoints(codec);
        return 0;
 
 };
 
 /* tosa audio map */
-static const char *audio_map[][3] = {
+static const snd_soc_dapm_route audio_map[] = {
 
        /* headphone connected to HPOUTL, HPOUTR */
        {"Headphone Jack", NULL, "HPOUTL"},
        {"Headset Jack", NULL, "HPOUTR"},
        {"LINEINR", NULL, "Mic Bias"},
        {"Mic Bias", NULL, "Headset Jack"},
-
-       {NULL, NULL, NULL},
 };
 
 static const char *jack_function[] = {"Headphone", "Mic", "Line", "Headset",
        }
 
        /* add tosa specific widgets */
-       for (i = 0; i < ARRAY_SIZE(tosa_dapm_widgets); i++) {
-               snd_soc_dapm_new_control(codec, &tosa_dapm_widgets[i]);
-       }
+       snd_soc_dapm_new_controls(codec, &tosa_dapm_widgets,
+                                 ARRAY_SIZE(tosa_dapm_widgets));
 
        /* set up tosa specific audio path audio_map */
-       for (i = 0; audio_map[i][0] != NULL; i++) {
-               snd_soc_dapm_connect_input(codec, audio_map[i][0],
-                       audio_map[i][1], audio_map[i][2]);
-       }
+       snd_soc_dapm_add_routes(codec, audio_map, ARRAY_SIZE(audio_map));
 
        snd_soc_dapm_sync_endpoints(codec);
        return 0;