aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/wm8988.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/codecs/wm8988.c')
-rw-r--r--sound/soc/codecs/wm8988.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sound/soc/codecs/wm8988.c b/sound/soc/codecs/wm8988.c
index 2862e4dced27..563cf898dafc 100644
--- a/sound/soc/codecs/wm8988.c
+++ b/sound/soc/codecs/wm8988.c
@@ -494,7 +494,7 @@ static int wm8988_set_dai_sysclk(struct snd_soc_dai *codec_dai,
494 int clk_id, unsigned int freq, int dir) 494 int clk_id, unsigned int freq, int dir)
495{ 495{
496 struct snd_soc_codec *codec = codec_dai->codec; 496 struct snd_soc_codec *codec = codec_dai->codec;
497 struct wm8988_priv *wm8988 = codec->private_data; 497 struct wm8988_priv *wm8988 = snd_soc_codec_get_drvdata(codec);
498 498
499 switch (freq) { 499 switch (freq) {
500 case 11289600: 500 case 11289600:
@@ -584,7 +584,7 @@ static int wm8988_pcm_startup(struct snd_pcm_substream *substream,
584 struct snd_soc_dai *dai) 584 struct snd_soc_dai *dai)
585{ 585{
586 struct snd_soc_codec *codec = dai->codec; 586 struct snd_soc_codec *codec = dai->codec;
587 struct wm8988_priv *wm8988 = codec->private_data; 587 struct wm8988_priv *wm8988 = snd_soc_codec_get_drvdata(codec);
588 588
589 /* The set of sample rates that can be supported depends on the 589 /* The set of sample rates that can be supported depends on the
590 * MCLK supplied to the CODEC - enforce this. 590 * MCLK supplied to the CODEC - enforce this.
@@ -609,7 +609,7 @@ static int wm8988_pcm_hw_params(struct snd_pcm_substream *substream,
609 struct snd_soc_pcm_runtime *rtd = substream->private_data; 609 struct snd_soc_pcm_runtime *rtd = substream->private_data;
610 struct snd_soc_device *socdev = rtd->socdev; 610 struct snd_soc_device *socdev = rtd->socdev;
611 struct snd_soc_codec *codec = socdev->card->codec; 611 struct snd_soc_codec *codec = socdev->card->codec;
612 struct wm8988_priv *wm8988 = codec->private_data; 612 struct wm8988_priv *wm8988 = snd_soc_codec_get_drvdata(codec);
613 u16 iface = snd_soc_read(codec, WM8988_IFACE) & 0x1f3; 613 u16 iface = snd_soc_read(codec, WM8988_IFACE) & 0x1f3;
614 u16 srate = snd_soc_read(codec, WM8988_SRATE) & 0x180; 614 u16 srate = snd_soc_read(codec, WM8988_SRATE) & 0x180;
615 int coeff; 615 int coeff;
@@ -832,7 +832,7 @@ static int wm8988_register(struct wm8988_priv *wm8988,
832 INIT_LIST_HEAD(&codec->dapm_widgets); 832 INIT_LIST_HEAD(&codec->dapm_widgets);
833 INIT_LIST_HEAD(&codec->dapm_paths); 833 INIT_LIST_HEAD(&codec->dapm_paths);
834 834
835 codec->private_data = wm8988; 835 snd_soc_codec_set_drvdata(codec, wm8988);
836 codec->name = "WM8988"; 836 codec->name = "WM8988";
837 codec->owner = THIS_MODULE; 837 codec->owner = THIS_MODULE;
838 codec->dai = &wm8988_dai; 838 codec->dai = &wm8988_dai;