Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 37f1ae92 authored by Bhalchandra Gajare's avatar Bhalchandra Gajare
Browse files

ASoC: msm8x10-wcd: Pull TX2 to micbias whenever micbias is enabled



It is noticed that the headset mic has a buzz whenever micbias is
enabled. To reduce this buzz, always pull up the TX2 (headset)
microphone front end to micbias.

CRs-fixed: 526901
Change-Id: Id007a4c34c68aea0d0e01743d3e7aa8ca09fd5f7
Signed-off-by: default avatarBhalchandra Gajare <gajare@codeaurora.org>
parent 0693d098
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -1607,6 +1607,9 @@ static int msm8x10_wcd_codec_enable_micbias(struct snd_soc_dapm_widget *w,
			snd_soc_update_bits(codec, micb_int_reg, 0x10, 0x10);
		else if (strnstr(w->name, internal3_text, 30))
			snd_soc_update_bits(codec, micb_int_reg, 0x2, 0x2);

		/* Always pull up TxFe for TX2 to Micbias */
		snd_soc_update_bits(codec, micb_int_reg, 0x04, 0x04);
		break;
	case SND_SOC_DAPM_POST_PMU:
		usleep_range(20000, 20100);
@@ -1624,6 +1627,8 @@ static int msm8x10_wcd_codec_enable_micbias(struct snd_soc_dapm_widget *w,
		else if (strnstr(w->name, internal3_text, 30))
			snd_soc_update_bits(codec, micb_int_reg, 0x2, 0x0);

		/* Disable pull up TxFe for TX2 to Micbias */
		snd_soc_update_bits(codec, micb_int_reg, 0x04, 0x00);
		break;
	}
	return 0;