ASoC: rockchip: rk817-codec: fix mic_in_differential as loopback fail issue

Change-Id: I6e69ec61a380f7a0ffc234aafcfdfb8e38654461
Signed-off-by: Binyuan Lan <lby@rock-chips.com>
This commit is contained in:
Binyuan Lan
2018-10-23 11:55:42 +08:00
committed by Tao Huang
parent 15ba079fa3
commit d9392291c8

View File

@@ -329,7 +329,7 @@ static struct rk817_reg_val_typ capture_power_up_list[] = {
{RK817_CODEC_DI2S_TXCR3_TXCMD, 0x88},
{RK817_CODEC_DDAC_POPD_DACST, 0x02},
/* 0x29: -18db to 27db */
{RK817_CODEC_DMIC_PGA_GAIN, 0xaa},
{RK817_CODEC_DMIC_PGA_GAIN, 0x99},
};
#define RK817_CODEC_CAPTURE_POWER_UP_LIST_LEN \
@@ -649,7 +649,7 @@ static int rk817_capture_path_put(struct snd_kcontrol *kcontrol,
if (rk817->adc_for_loopback) {
/* don't need to gain when adc use for loopback */
snd_soc_write(codec, RK817_CODEC_AMIC_CFG0, 0x00);
snd_soc_update_bits(codec, RK817_CODEC_AMIC_CFG0, 0xf, 0x0);
snd_soc_write(codec, RK817_CODEC_DMIC_PGA_GAIN, 0x66);
snd_soc_write(codec, RK817_CODEC_DADC_VOLL, 0x00);
snd_soc_write(codec, RK817_CODEC_DADC_VOLR, 0x00);
@@ -669,7 +669,7 @@ static int rk817_capture_path_put(struct snd_kcontrol *kcontrol,
if (rk817->adc_for_loopback) {
/* don't need to gain when adc use for loopback */
snd_soc_write(codec, RK817_CODEC_AMIC_CFG0, 0x00);
snd_soc_update_bits(codec, RK817_CODEC_AMIC_CFG0, 0xf, 0x0);
snd_soc_write(codec, RK817_CODEC_DMIC_PGA_GAIN, 0x66);
snd_soc_write(codec, RK817_CODEC_DADC_VOLL, 0x00);
snd_soc_write(codec, RK817_CODEC_DADC_VOLR, 0x00);