ASoC: pcm512x: Replace direct snd_soc_codec dapm field access
authorLars-Peter Clausen <lars@metafoo.de>
Fri, 15 May 2015 10:32:55 +0000 (12:32 +0200)
committerMark Brown <broonie@kernel.org>
Fri, 15 May 2015 15:48:56 +0000 (16:48 +0100)
The dapm field of the snd_soc_codec struct is eventually going to be
removed, in preparation for this replace all manual access to
codec->dapm.bias_level with snd_soc_codec_get_bias_level().

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/pcm512x.c

index c305b28..de16429 100644 (file)
@@ -242,7 +242,7 @@ static int pcm512x_overclock_pll_put(struct snd_kcontrol *kcontrol,
        struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
        struct pcm512x_priv *pcm512x = snd_soc_codec_get_drvdata(codec);
 
-       switch (codec->dapm.bias_level) {
+       switch (snd_soc_codec_get_bias_level(codec)) {
        case SND_SOC_BIAS_OFF:
        case SND_SOC_BIAS_STANDBY:
                break;
@@ -270,7 +270,7 @@ static int pcm512x_overclock_dsp_put(struct snd_kcontrol *kcontrol,
        struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
        struct pcm512x_priv *pcm512x = snd_soc_codec_get_drvdata(codec);
 
-       switch (codec->dapm.bias_level) {
+       switch (snd_soc_codec_get_bias_level(codec)) {
        case SND_SOC_BIAS_OFF:
        case SND_SOC_BIAS_STANDBY:
                break;
@@ -298,7 +298,7 @@ static int pcm512x_overclock_dac_put(struct snd_kcontrol *kcontrol,
        struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
        struct pcm512x_priv *pcm512x = snd_soc_codec_get_drvdata(codec);
 
-       switch (codec->dapm.bias_level) {
+       switch (snd_soc_codec_get_bias_level(codec)) {
        case SND_SOC_BIAS_OFF:
        case SND_SOC_BIAS_STANDBY:
                break;