summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYeleswarapu Nagaradhesh <nagaradh@codeaurora.org>2016-03-22 17:28:02 +0530
committerJeevan Shriram <jshriram@codeaurora.org>2016-05-06 12:06:18 -0700
commitc72b107db637e57af6e8f3cfc6b8f3b614d3101e (patch)
treed0200c61d7e82b94529b1f9aaa2f837f9e0491aa
parent483f6782478b5980a13c3c13109eaa0167ada385 (diff)
ASoC: wcd-mbhc: Fix special headset detection issue
Even if the first measurement of hs_comp_result is 0 after micbias is increased to 2.7v, it should be reported as special headset. Fix the condition in driver to handle this scenario. CRs-Fixed: 993103 Change-Id: I859e9de29436af12ef1af0e2ed85bcbb51d2e27a Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
-rw-r--r--sound/soc/codecs/wcd-mbhc-v2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/codecs/wcd-mbhc-v2.c b/sound/soc/codecs/wcd-mbhc-v2.c
index 33cce5ee17cc..af6eee12d05a 100644
--- a/sound/soc/codecs/wcd-mbhc-v2.c
+++ b/sound/soc/codecs/wcd-mbhc-v2.c
@@ -937,7 +937,7 @@ static bool wcd_is_special_headset(struct wcd_mbhc *mbhc)
pr_debug("%s: special headset, start register writes\n", __func__);
WCD_MBHC_REG_READ(WCD_MBHC_HS_COMP_RESULT, hs_comp_res);
- while (hs_comp_res) {
+ while (!is_spl_hs) {
if (mbhc->hs_detect_work_stop) {
pr_debug("%s: stop requested: %d\n", __func__,
mbhc->hs_detect_work_stop);