diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-11-22 18:19:41 -0500 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-11-23 05:00:34 -0500 |
commit | 1db3c98e18962557ce9d9fd0b895c8a6e41c96fd (patch) | |
tree | 5e5e93d3efd4693dd494235d94a38170e20d1483 /sound | |
parent | 404417e6b49694931241aada4209e1ec0b4eefee (diff) |
ASoC: Convert wm8776 to table based control and DAPM init
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound')
-rw-r--r-- | sound/soc/codecs/wm8776.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/sound/soc/codecs/wm8776.c b/sound/soc/codecs/wm8776.c index bfdc52370ad0..f967c59dbbef 100644 --- a/sound/soc/codecs/wm8776.c +++ b/sound/soc/codecs/wm8776.c | |||
@@ -414,12 +414,6 @@ static int wm8776_probe(struct snd_soc_codec *codec) | |||
414 | snd_soc_update_bits(codec, WM8776_HPRVOL, 0x100, 0x100); | 414 | snd_soc_update_bits(codec, WM8776_HPRVOL, 0x100, 0x100); |
415 | snd_soc_update_bits(codec, WM8776_DACRVOL, 0x100, 0x100); | 415 | snd_soc_update_bits(codec, WM8776_DACRVOL, 0x100, 0x100); |
416 | 416 | ||
417 | snd_soc_add_controls(codec, wm8776_snd_controls, | ||
418 | ARRAY_SIZE(wm8776_snd_controls)); | ||
419 | snd_soc_dapm_new_controls(dapm, wm8776_dapm_widgets, | ||
420 | ARRAY_SIZE(wm8776_dapm_widgets)); | ||
421 | snd_soc_dapm_add_routes(dapm, routes, ARRAY_SIZE(routes)); | ||
422 | |||
423 | return ret; | 417 | return ret; |
424 | } | 418 | } |
425 | 419 | ||
@@ -439,6 +433,13 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8776 = { | |||
439 | .reg_cache_size = ARRAY_SIZE(wm8776_reg), | 433 | .reg_cache_size = ARRAY_SIZE(wm8776_reg), |
440 | .reg_word_size = sizeof(u16), | 434 | .reg_word_size = sizeof(u16), |
441 | .reg_cache_default = wm8776_reg, | 435 | .reg_cache_default = wm8776_reg, |
436 | |||
437 | .controls = wm8776_snd_controls, | ||
438 | .num_controls = ARRAY_SIZE(wm8776_snd_controls), | ||
439 | .dapm_widgets = wm8776_dapm_widgets, | ||
440 | .num_dapm_widgets = ARRAY_SIZE(wm8776_dapm_widgets), | ||
441 | .dapm_routes = routes, | ||
442 | .num_dapm_routes = ARRAY_SIZE(routes), | ||
442 | }; | 443 | }; |
443 | 444 | ||
444 | static const struct of_device_id wm8776_of_match[] = { | 445 | static const struct of_device_id wm8776_of_match[] = { |