From a1dc65d39b2b3fe1cd05b25abf168f145cbc4a53 Mon Sep 17 00:00:00 2001 From: Binyuan Lan Date: Tue, 11 Sep 2018 23:40:43 +0800 Subject: [PATCH] ASoC: rockchip: rk817-codec: optimize the reset operation Solve the problem of small recording amplitude in the first recording. Change-Id: I268f56b1a2c5a16da958952fe06ce11ada1cf932 Signed-off-by: Binyuan Lan --- sound/soc/codecs/rk817_codec.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sound/soc/codecs/rk817_codec.c b/sound/soc/codecs/rk817_codec.c index 82e6c56c1228..e3cbe7eeed24 100644 --- a/sound/soc/codecs/rk817_codec.c +++ b/sound/soc/codecs/rk817_codec.c @@ -251,6 +251,14 @@ static int rk817_reset(struct snd_soc_codec *codec) { snd_soc_write(codec, RK817_CODEC_DTOP_LPT_SRST, 0x40); snd_soc_write(codec, RK817_CODEC_DDAC_POPD_DACST, 0x02); + snd_soc_write(codec, RK817_CODEC_DTOP_DIGEN_CLKE, 0x0f); + snd_soc_write(codec, RK817_CODEC_APLL_CFG0, 0x04); + snd_soc_write(codec, RK817_CODEC_APLL_CFG1, 0x58); + snd_soc_write(codec, RK817_CODEC_APLL_CFG2, 0x2d); + snd_soc_write(codec, RK817_CODEC_APLL_CFG3, 0x0c); + snd_soc_write(codec, RK817_CODEC_APLL_CFG4, 0xa5); + snd_soc_write(codec, RK817_CODEC_APLL_CFG5, 0x00); + snd_soc_write(codec, RK817_CODEC_DTOP_DIGEN_CLKE, 0x00); return 0; }