]> git.baikalelectronics.ru Git - kernel.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)
committerMark Brown <broonie@kernel.org>
Tue, 20 Aug 2019 17:36:51 +0000 (18:36 +0100)
commit4676ff4f8a5ed920e37f84b70bdd71e0ecfb734e
treee1d7cb02ef47876656fae49c7f10017a1f4fcf0a
parent73921f5a5a4068c62c6ee39ec1e38999d0dfb202
ASoC: mchp-i2s-mcc: Wait for RX/TX RDY only if controller is running

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>
sound/soc/atmel/mchp-i2s-mcc.c