From 18c89c9b5fd8b59d4690479ef110b6e9c77291df Mon Sep 17 00:00:00 2001 From: Yuhui Zhao Date: Thu, 11 Apr 2024 17:41:27 +0800 Subject: [PATCH] asoc: optimize the init sequence for tambora Optimize the init sequence for tambora, enable TXSCBIAS_CLK and set IBIAS_LDO_DRIVER as 5ua. Change-Id: I639b7051d03d167972f592b155072260d4e02aec Signed-off-by: Yuhui Zhao --- asoc/codecs/wcd9378/wcd9378-mbhc.c | 10 ++-------- asoc/codecs/wcd9378/wcd9378.c | 6 ++++++ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/asoc/codecs/wcd9378/wcd9378-mbhc.c b/asoc/codecs/wcd9378/wcd9378-mbhc.c index 5b311abcea..618d65551d 100644 --- a/asoc/codecs/wcd9378/wcd9378-mbhc.c +++ b/asoc/codecs/wcd9378/wcd9378-mbhc.c @@ -193,18 +193,12 @@ static int wcd9378_mbhc_free_irq(struct snd_soc_component *component, static void wcd9378_mbhc_clk_setup(struct snd_soc_component *component, bool enable) { - if (enable) { + if (enable) snd_soc_component_update_bits(component, WCD9378_MBHC_NEW_CTL_1, 0x80, 0x80); - snd_soc_component_update_bits(component, WCD9378_CDC_ANA_TX_CLK_CTL, - 0x01, 0x01); - } else { + else snd_soc_component_update_bits(component, WCD9378_MBHC_NEW_CTL_1, 0x80, 0x00); - snd_soc_component_update_bits(component, WCD9378_CDC_ANA_TX_CLK_CTL, - 0x01, 0x00); - - } } static int wcd9378_mbhc_btn_to_num(struct snd_soc_component *component) diff --git a/asoc/codecs/wcd9378/wcd9378.c b/asoc/codecs/wcd9378/wcd9378.c index d810b93c20..7fc4a68ce5 100644 --- a/asoc/codecs/wcd9378/wcd9378.c +++ b/asoc/codecs/wcd9378/wcd9378.c @@ -315,6 +315,9 @@ static int wcd9378_init_reg(struct snd_soc_component *component) WCD9378_ANA_BIAS_PRECHRG_EN_MASK, 0x00); /*End Analog Master Bias enable*/ + /*ANA_TXSCBIAS_CLK_EN ENABLE*/ + snd_soc_component_update_bits(component, WCD9378_CDC_ANA_TX_CLK_CTL, + WCD9378_CDC_ANA_TX_CLK_CTL_ANA_TXSCBIAS_CLK_EN_MASK, 0x01); /*SEQ_BYPASS ENABLE*/ snd_soc_component_update_bits(component, WCD9378_TX_COM_TXFE_DIV_CTL, WCD9378_TX_COM_TXFE_DIV_CTL_SEQ_BYPASS_MASK, 0x80); @@ -328,6 +331,9 @@ static int wcd9378_init_reg(struct snd_soc_component *component) snd_soc_component_update_bits(component, WCD9378_MICB1_TEST_CTL_2, WCD9378_MICB1_TEST_CTL_2_IBIAS_LDO_DRIVER_MASK, 0x01); /*IBIAS_LDO_DRIVER 5e-06*/ + snd_soc_component_update_bits(component, WCD9378_MICB2_TEST_CTL_2, + WCD9378_MICB2_TEST_CTL_2_IBIAS_LDO_DRIVER_MASK, 0x01); + /*IBIAS_LDO_DRIVER 5e-06*/ snd_soc_component_update_bits(component, WCD9378_MICB3_TEST_CTL_2, WCD9378_MICB3_TEST_CTL_2_IBIAS_LDO_DRIVER_MASK, 0x01);