diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-10-10 07:41:37 -0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-10-14 22:49:41 -0400 |
commit | c6300bb83f9374569284c4e75dec1cc6be4fb455 (patch) | |
tree | 89bc0a6fa8c37bd2685b61f8f847a1f5427e3168 | |
parent | f81ad9421a49107a9d12f902af3373fbcd808288 (diff) |
ASoC: wm8770: Conver to table based DAPM and control init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
-rw-r--r-- | sound/soc/codecs/wm8770.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sound/soc/codecs/wm8770.c b/sound/soc/codecs/wm8770.c index 90920315f536..0b690ba875f8 100644 --- a/sound/soc/codecs/wm8770.c +++ b/sound/soc/codecs/wm8770.c | |||
@@ -614,13 +614,6 @@ static int wm8770_probe(struct snd_soc_codec *codec) | |||
614 | /* mute all DACs */ | 614 | /* mute all DACs */ |
615 | snd_soc_update_bits(codec, WM8770_DACMUTE, 0x10, 0x10); | 615 | snd_soc_update_bits(codec, WM8770_DACMUTE, 0x10, 0x10); |
616 | 616 | ||
617 | snd_soc_add_codec_controls(codec, wm8770_snd_controls, | ||
618 | ARRAY_SIZE(wm8770_snd_controls)); | ||
619 | snd_soc_dapm_new_controls(&codec->dapm, wm8770_dapm_widgets, | ||
620 | ARRAY_SIZE(wm8770_dapm_widgets)); | ||
621 | snd_soc_dapm_add_routes(&codec->dapm, wm8770_intercon, | ||
622 | ARRAY_SIZE(wm8770_intercon)); | ||
623 | |||
624 | err_reg_enable: | 617 | err_reg_enable: |
625 | regulator_bulk_disable(ARRAY_SIZE(wm8770->supplies), wm8770->supplies); | 618 | regulator_bulk_disable(ARRAY_SIZE(wm8770->supplies), wm8770->supplies); |
626 | return ret; | 619 | return ret; |
@@ -630,6 +623,13 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8770 = { | |||
630 | .probe = wm8770_probe, | 623 | .probe = wm8770_probe, |
631 | .set_bias_level = wm8770_set_bias_level, | 624 | .set_bias_level = wm8770_set_bias_level, |
632 | .idle_bias_off = true, | 625 | .idle_bias_off = true, |
626 | |||
627 | .controls = wm8770_snd_controls, | ||
628 | .num_controls = ARRAY_SIZE(wm8770_snd_controls), | ||
629 | .dapm_widgets = wm8770_dapm_widgets, | ||
630 | .num_dapm_widgets = ARRAY_SIZE(wm8770_dapm_widgets), | ||
631 | .dapm_routes = wm8770_intercon, | ||
632 | .num_dapm_routes = ARRAY_SIZE(wm8770_intercon), | ||
633 | }; | 633 | }; |
634 | 634 | ||
635 | static const struct of_device_id wm8770_of_match[] = { | 635 | static const struct of_device_id wm8770_of_match[] = { |