Skip to content

Commit

Permalink
ASoC: wcd938x: Fix jack detection issue
Browse files Browse the repository at this point in the history
This patch is to fix audio 3.5mm jack detection failure
on wcd938x codec based target.

Fixes: bcee7ed (ASoC: codecs: wcd938x: add Multi Button Headset Control support)

Signed-off-by: Venkata Prasad Potturu <potturu@codeaurora.org>
Signed-off-by: Srinivasa Rao Mandadapu <srivasam@codeaurora.org>
Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Link: https://lore.kernel.org/r/1633614619-27026-1-git-send-email-srivasam@codeaurora.org
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Srinivasa Rao Mandadapu authored and broonie committed Oct 7, 2021
1 parent 42871e9 commit db0767b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions sound/soc/codecs/wcd938x.c
Expand Up @@ -4144,10 +4144,10 @@ static int wcd938x_codec_set_jack(struct snd_soc_component *comp,
{
struct wcd938x_priv *wcd = dev_get_drvdata(comp->dev);

if (!jack)
if (jack)
return wcd_mbhc_start(wcd->wcd_mbhc, &wcd->mbhc_cfg, jack);

wcd_mbhc_stop(wcd->wcd_mbhc);
else
wcd_mbhc_stop(wcd->wcd_mbhc);

return 0;
}
Expand Down

0 comments on commit db0767b

Please sign in to comment.