]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: sof_es8336: reduce pop noise on speaker
authorZhu Ning <zhuning0077@gmail.com>
Fri, 28 Oct 2022 02:04:56 +0000 (10:04 +0800)
committerMark Brown <broonie@kernel.org>
Mon, 7 Nov 2022 13:58:03 +0000 (13:58 +0000)
commit1b9cb679e4e5a8a05ff1b827060d1694b6d43312
treed10de68ee933cf0e8b5c499503c862063dbf684c
parent02416962f77cda7c43afed2a6635d1543cbd9c8d
ASoC: sof_es8336: reduce pop noise on speaker

The Speaker GPIO needs to be turned on slightly behind the codec turned on.
It also need to be turned off slightly before the codec turned down.
Current code uses delay in DAPM_EVENT to do it but the mdelay delays the
DAPM itself and thus has no effect. A delayed_work is added to turn on the
speaker.
The Speaker is turned off in .trigger since trigger is called slightly
before the DAPM events.

Signed-off-by: Zhu Ning <zhuning@everest-semi.com>
------------

v1: cancel delayed work while disabling speaker.
Link: https://lore.kernel.org/r/20221028020456.90286-1-zhuning0077@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/intel/boards/sof_es8336.c