]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ASoC: mchp-i2s-mcc: Wait for RX/TX RDY only if controller is running
authorCodrin Ciubotariu <codrin.ciubotariu@microchip.com>
Tue, 20 Aug 2019 16:24:10 +0000 (19:24 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 5 Oct 2019 11:13:43 +0000 (13:13 +0200)
commit78a5d757035769eff4ad86c7745ae4654c223434
treef140eb1de1fc80af0c2ef7ac32ab918757115886
parentcf37fc6525e63ec012cca25eda796c75e77dbd99
ASoC: mchp-i2s-mcc: Wait for RX/TX RDY only if controller is running

[ Upstream commit 0f6fc97501b790c971b11b52a654009d21c45238 ]

Since hw_free() can be called multiple times and not just after a stop
trigger command, we should check whether the RX or TX ready interrupt was
truly enabled previously. For this, we assure that the condition of the
wait event is always true, except when RX/TX interrupts are enabled.

Fixes: 7e0cdf545a55 ("ASoC: mchp-i2s-mcc: add driver for I2SC Multi-Channel Controller")
Signed-off-by: Codrin Ciubotariu <codrin.ciubotariu@microchip.com>
Link: https://lore.kernel.org/r/20190820162411.24836-3-codrin.ciubotariu@microchip.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
sound/soc/atmel/mchp-i2s-mcc.c