asoc: Enable RT5639 revD mclk code
Scott Peterson [Tue, 3 Dec 2013 17:05:21 +0000 (09:05 -0800)]
Enable the MCLK detection circuit in the
RevD version of the ALC5639 audio codec

Bug 1413194
BUg 1408553

Change-Id: I09b72c8e609f580b9f81dac2baafae0f418bc956
Signed-off-by: Scott Peterson <speterson@nvidia.com>
Reviewed-on: http://git-master/r/338025
Reviewed-by: Raymond Poudrier <rapoudrier@nvidia.com>
GVS: Gerrit_Virtual_Submit

sound/soc/codecs/rt5639.c

index 04cec14..50b55dd 100644 (file)
@@ -519,7 +519,7 @@ int rt5639_headset_detect(struct snd_soc_codec *codec, int jack_insert)
                if (SND_SOC_BIAS_OFF == codec->dapm.bias_level) {
                        snd_soc_write(codec, RT5639_PWR_ANLG1, 0xa814);
                        snd_soc_write(codec, RT5639_MICBIAS, 0x3830);
-                       snd_soc_write(codec, RT5639_GEN_CTRL1 , 0x3701);
+                       snd_soc_write(codec, RT5639_GEN_CTRL1 , 0x3F01);
                    sclk_src = snd_soc_read(codec, RT5639_GLB_CLK) &
                            RT5639_SCLK_SRC_MASK;
                    snd_soc_update_bits(codec, RT5639_GLB_CLK,
@@ -2964,7 +2964,7 @@ static int rt5639_set_bias_level(struct snd_soc_codec *codec,
                        snd_soc_update_bits(codec, RT5639_PWR_ANLG1,
                                RT5639_PWR_FV1 | RT5639_PWR_FV2,
                                RT5639_PWR_FV1 | RT5639_PWR_FV2);
-                       snd_soc_write(codec, RT5639_GEN_CTRL1, 0x3701);
+                       snd_soc_write(codec, RT5639_GEN_CTRL1, 0x3F01);
                        codec->cache_only = false;
                        codec->cache_sync = 1;
                        snd_soc_cache_sync(codec);
@@ -2975,7 +2975,7 @@ static int rt5639_set_bias_level(struct snd_soc_codec *codec,
        case SND_SOC_BIAS_OFF:
                snd_soc_write(codec, RT5639_DEPOP_M1, 0x0004);
                snd_soc_write(codec, RT5639_DEPOP_M2, 0x1100);
-               snd_soc_write(codec, RT5639_GEN_CTRL1, 0x3700);
+               snd_soc_write(codec, RT5639_GEN_CTRL1, 0x3F00);
                snd_soc_write(codec, RT5639_PWR_DIG1, 0x0000);
                snd_soc_write(codec, RT5639_PWR_DIG2, 0x0000);
                snd_soc_write(codec, RT5639_PWR_VOL, 0x0000);