diff options
Diffstat (limited to 'sound/soc/codecs/wm8580.c')
-rw-r--r-- | sound/soc/codecs/wm8580.c | 30 |
1 files changed, 2 insertions, 28 deletions
diff --git a/sound/soc/codecs/wm8580.c b/sound/soc/codecs/wm8580.c index 6bded8c78150..d077df6f5e75 100644 --- a/sound/soc/codecs/wm8580.c +++ b/sound/soc/codecs/wm8580.c | |||
@@ -315,7 +315,6 @@ static int wm8580_add_widgets(struct snd_soc_codec *codec) | |||
315 | 315 | ||
316 | snd_soc_dapm_add_routes(codec, audio_map, ARRAY_SIZE(audio_map)); | 316 | snd_soc_dapm_add_routes(codec, audio_map, ARRAY_SIZE(audio_map)); |
317 | 317 | ||
318 | snd_soc_dapm_new_widgets(codec); | ||
319 | return 0; | 318 | return 0; |
320 | } | 319 | } |
321 | 320 | ||
@@ -407,8 +406,8 @@ static int pll_factors(struct _pll_div *pll_div, unsigned int target, | |||
407 | return 0; | 406 | return 0; |
408 | } | 407 | } |
409 | 408 | ||
410 | static int wm8580_set_dai_pll(struct snd_soc_dai *codec_dai, | 409 | static int wm8580_set_dai_pll(struct snd_soc_dai *codec_dai, int pll_id, |
411 | int pll_id, unsigned int freq_in, unsigned int freq_out) | 410 | int source, unsigned int freq_in, unsigned int freq_out) |
412 | { | 411 | { |
413 | int offset; | 412 | int offset; |
414 | struct snd_soc_codec *codec = codec_dai->codec; | 413 | struct snd_soc_codec *codec = codec_dai->codec; |
@@ -800,17 +799,9 @@ static int wm8580_probe(struct platform_device *pdev) | |||
800 | snd_soc_add_controls(codec, wm8580_snd_controls, | 799 | snd_soc_add_controls(codec, wm8580_snd_controls, |
801 | ARRAY_SIZE(wm8580_snd_controls)); | 800 | ARRAY_SIZE(wm8580_snd_controls)); |
802 | wm8580_add_widgets(codec); | 801 | wm8580_add_widgets(codec); |
803 | ret = snd_soc_init_card(socdev); | ||
804 | if (ret < 0) { | ||
805 | dev_err(codec->dev, "failed to register card: %d\n", ret); | ||
806 | goto card_err; | ||
807 | } | ||
808 | 802 | ||
809 | return ret; | 803 | return ret; |
810 | 804 | ||
811 | card_err: | ||
812 | snd_soc_free_pcms(socdev); | ||
813 | snd_soc_dapm_free(socdev); | ||
814 | pcm_err: | 805 | pcm_err: |
815 | return ret; | 806 | return ret; |
816 | } | 807 | } |
@@ -961,21 +952,6 @@ static int wm8580_i2c_remove(struct i2c_client *client) | |||
961 | return 0; | 952 | return 0; |
962 | } | 953 | } |
963 | 954 | ||
964 | #ifdef CONFIG_PM | ||
965 | static int wm8580_i2c_suspend(struct i2c_client *client, pm_message_t msg) | ||
966 | { | ||
967 | return snd_soc_suspend_device(&client->dev); | ||
968 | } | ||
969 | |||
970 | static int wm8580_i2c_resume(struct i2c_client *client) | ||
971 | { | ||
972 | return snd_soc_resume_device(&client->dev); | ||
973 | } | ||
974 | #else | ||
975 | #define wm8580_i2c_suspend NULL | ||
976 | #define wm8580_i2c_resume NULL | ||
977 | #endif | ||
978 | |||
979 | static const struct i2c_device_id wm8580_i2c_id[] = { | 955 | static const struct i2c_device_id wm8580_i2c_id[] = { |
980 | { "wm8580", 0 }, | 956 | { "wm8580", 0 }, |
981 | { } | 957 | { } |
@@ -989,8 +965,6 @@ static struct i2c_driver wm8580_i2c_driver = { | |||
989 | }, | 965 | }, |
990 | .probe = wm8580_i2c_probe, | 966 | .probe = wm8580_i2c_probe, |
991 | .remove = wm8580_i2c_remove, | 967 | .remove = wm8580_i2c_remove, |
992 | .suspend = wm8580_i2c_suspend, | ||
993 | .resume = wm8580_i2c_resume, | ||
994 | .id_table = wm8580_i2c_id, | 968 | .id_table = wm8580_i2c_id, |
995 | }; | 969 | }; |
996 | #endif | 970 | #endif |