forked from luck/tmp_suning_uos_patched
ASoC: Report error code when failing to add controls
Helps with diagnostics. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
This commit is contained in:
parent
17cc26cd8c
commit
082100dc92
@ -1982,8 +1982,8 @@ int snd_soc_add_controls(struct snd_soc_codec *codec,
|
|||||||
const struct snd_kcontrol_new *control = &controls[i];
|
const struct snd_kcontrol_new *control = &controls[i];
|
||||||
err = snd_ctl_add(card, snd_soc_cnew(control, codec, NULL));
|
err = snd_ctl_add(card, snd_soc_cnew(control, codec, NULL));
|
||||||
if (err < 0) {
|
if (err < 0) {
|
||||||
dev_err(codec->dev, "%s: Failed to add %s\n",
|
dev_err(codec->dev, "%s: Failed to add %s: %d\n",
|
||||||
codec->name, control->name);
|
codec->name, control->name, err);
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user