ASoC: rt1011: add mutex protection to set_fmt/set_tdm_slot
authorShuming Fan <shumingf@realtek.com>
Mon, 26 Aug 2019 09:00:52 +0000 (17:00 +0800)
committerMark Brown <broonie@kernel.org>
Tue, 27 Aug 2019 19:38:42 +0000 (20:38 +0100)
commite9e897d5fdba9bda3a8c80ea39761413725f198c
treeb50e9407ffd79683ecddca91d1cdd7cf3c046229
parentf6e77921969003eaf5dbae9c0b5feeb20c6caf50
ASoC: rt1011: add mutex protection to set_fmt/set_tdm_slot

The calibration process at booting will reset registers and bypass cache
to make sure the calibration is done.
We add mutex protection to avoid unexpected settings while
the registration process and calibration are interleaved.

Signed-off-by: Shuming Fan <shumingf@realtek.com>
Link: https://lore.kernel.org/r/20190826090052.1875-1-shumingf@realtek.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/rt1011.c