soundwire: qcom: wait for fifo space to be available before read/write
authorSrinivas Kandagatla <srinivas.kandagatla@linaro.org>
Thu, 1 Apr 2021 09:00:58 +0000 (10:00 +0100)
committerVinod Koul <vkoul@kernel.org>
Tue, 6 Apr 2021 04:53:58 +0000 (10:23 +0530)
commita661308c34de8cbd22165edf63dbd24ccb914981
tree2715e03a0af2ab89454320f54248036c6280b4c2
parenteb5a909441a896fe9e230086363284a09c23e5df
soundwire: qcom: wait for fifo space to be available before read/write

If we write registers very fast we can endup in a situation where some
of the writes will be dropped without any notice.

So wait for the fifo space to be available before reading/writing the
soundwire registers.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Link: https://lore.kernel.org/r/20210401090058.24041-1-srinivas.kandagatla@linaro.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/soundwire/qcom.c