ASoC: Display the error code when we fail to add a DAPM control
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 5 Sep 2011 17:51:05 +0000 (10:51 -0700)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 19 Sep 2011 10:27:22 +0000 (11:27 +0100)
Useful for diagnostics.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
sound/soc/soc-dapm.c

index 4859ad77eac79d73375f7630f87c70a8dfd2185d..4a440b52dd7af8f9471a21e8f49ec34c5256e690 100644 (file)
@@ -584,8 +584,8 @@ static int dapm_new_mux(struct snd_soc_dapm_widget *w)
                                        name + prefix_len, prefix);
                ret = snd_ctl_add(card, kcontrol);
                if (ret < 0) {
-                       dev_err(dapm->dev,
-                               "asoc: failed to add kcontrol %s\n", w->name);
+                       dev_err(dapm->dev, "failed to add kcontrol %s: %d\n",
+                               w->name, ret);
                        kfree(wlist);
                        return ret;
                }