aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/wm8753.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/codecs/wm8753.c')
-rw-r--r--sound/soc/codecs/wm8753.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/sound/soc/codecs/wm8753.c b/sound/soc/codecs/wm8753.c
index be85da93a268..cbb8d55052a4 100644
--- a/sound/soc/codecs/wm8753.c
+++ b/sound/soc/codecs/wm8753.c
@@ -251,7 +251,7 @@ static int wm8753_set_dai(struct snd_kcontrol *kcontrol,
251 if (wm8753->dai_func == ucontrol->value.integer.value[0]) 251 if (wm8753->dai_func == ucontrol->value.integer.value[0])
252 return 0; 252 return 0;
253 253
254 if (codec->active) 254 if (snd_soc_codec_is_active(codec))
255 return -EBUSY; 255 return -EBUSY;
256 256
257 ioctl = snd_soc_read(codec, WM8753_IOCTL); 257 ioctl = snd_soc_read(codec, WM8753_IOCTL);
@@ -1314,7 +1314,7 @@ static int wm8753_mute(struct snd_soc_dai *dai, int mute)
1314 /* the digital mute covers the HiFi and Voice DAC's on the WM8753. 1314 /* the digital mute covers the HiFi and Voice DAC's on the WM8753.
1315 * make sure we check if they are not both active when we mute */ 1315 * make sure we check if they are not both active when we mute */
1316 if (mute && wm8753->dai_func == 1) { 1316 if (mute && wm8753->dai_func == 1) {
1317 if (!codec->active) 1317 if (!snd_soc_codec_is_active(codec))
1318 snd_soc_write(codec, WM8753_DAC, mute_reg | 0x8); 1318 snd_soc_write(codec, WM8753_DAC, mute_reg | 0x8);
1319 } else { 1319 } else {
1320 if (mute) 1320 if (mute)
@@ -1440,7 +1440,6 @@ static void wm8753_work(struct work_struct *work)
1440static int wm8753_suspend(struct snd_soc_codec *codec) 1440static int wm8753_suspend(struct snd_soc_codec *codec)
1441{ 1441{
1442 wm8753_set_bias_level(codec, SND_SOC_BIAS_OFF); 1442 wm8753_set_bias_level(codec, SND_SOC_BIAS_OFF);
1443 codec->cache_sync = 1;
1444 return 0; 1443 return 0;
1445} 1444}
1446 1445
@@ -1471,13 +1470,6 @@ static int wm8753_probe(struct snd_soc_codec *codec)
1471 1470
1472 INIT_DELAYED_WORK(&codec->dapm.delayed_work, wm8753_work); 1471 INIT_DELAYED_WORK(&codec->dapm.delayed_work, wm8753_work);
1473 1472
1474 codec->control_data = wm8753->regmap;
1475 ret = snd_soc_codec_set_cache_io(codec, 7, 9, SND_SOC_REGMAP);
1476 if (ret < 0) {
1477 dev_err(codec->dev, "Failed to set cache I/O: %d\n", ret);
1478 return ret;
1479 }
1480
1481 ret = wm8753_reset(codec); 1473 ret = wm8753_reset(codec);
1482 if (ret < 0) { 1474 if (ret < 0) {
1483 dev_err(codec->dev, "Failed to issue reset: %d\n", ret); 1475 dev_err(codec->dev, "Failed to issue reset: %d\n", ret);