aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/pxa/tosa.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/pxa/tosa.c')
-rw-r--r--sound/soc/pxa/tosa.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/sound/soc/pxa/tosa.c b/sound/soc/pxa/tosa.c
index 09b5bada03b9..fc781374b1bf 100644
--- a/sound/soc/pxa/tosa.c
+++ b/sound/soc/pxa/tosa.c
@@ -188,18 +188,16 @@ static const struct snd_kcontrol_new tosa_controls[] = {
188 188
189static int tosa_ac97_init(struct snd_soc_codec *codec) 189static int tosa_ac97_init(struct snd_soc_codec *codec)
190{ 190{
191 int i, err; 191 int err;
192 192
193 snd_soc_dapm_nc_pin(codec, "OUT3"); 193 snd_soc_dapm_nc_pin(codec, "OUT3");
194 snd_soc_dapm_nc_pin(codec, "MONOOUT"); 194 snd_soc_dapm_nc_pin(codec, "MONOOUT");
195 195
196 /* add tosa specific controls */ 196 /* add tosa specific controls */
197 for (i = 0; i < ARRAY_SIZE(tosa_controls); i++) { 197 err = snd_soc_add_controls(codec, tosa_controls,
198 err = snd_ctl_add(codec->card, 198 ARRAY_SIZE(tosa_controls));
199 snd_soc_cnew(&tosa_controls[i],codec, NULL)); 199 if (err < 0)
200 if (err < 0) 200 return err;
201 return err;
202 }
203 201
204 /* add tosa specific widgets */ 202 /* add tosa specific widgets */
205 snd_soc_dapm_new_controls(codec, tosa_dapm_widgets, 203 snd_soc_dapm_new_controls(codec, tosa_dapm_widgets,