]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: rt5682s: Fix the wrong jack type detected
authorDerek Fang <derek.fang@realtek.com>
Wed, 23 Feb 2022 10:14:50 +0000 (18:14 +0800)
committerMark Brown <broonie@kernel.org>
Thu, 24 Feb 2022 02:04:33 +0000 (02:04 +0000)
commit416e06a724555cfac487ce1985772e3388c5da5f
tree57227e9a52a87d9561c3feb74d18115b79e73be2
parenta24d69f0aa2ea6d313e1917b4855d1d60b7ab584
ASoC: rt5682s: Fix the wrong jack type detected

Some powers were changed during the jack insert detection and clk's
enable/disable in CCF.
If in parallel, the influence has a chance to detect the wrong jack
type.

We refer to the below commit of the variant codec (rt5682) to fix
this issue.
  ASoC: rt5682: Fix deadlock on resume

1. Remove rt5682s_headset_detect in rt5682s_jd_check_handler and
   use jack_detect_work instead of.
2. Use dapm mutex used in CCF to protect most of jack_detect_work.

Signed-off-by: Derek Fang <derek.fang@realtek.com>
Link: https://lore.kernel.org/r/20220223101450.4577-1-derek.fang@realtek.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/rt5682s.c
sound/soc/codecs/rt5682s.h