ASoC: mchp-spdifrx: fix return value in case completion times out
authorClaudiu Beznea <claudiu.beznea@microchip.com>
Mon, 30 Jan 2023 12:06:41 +0000 (14:06 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 08:39:27 +0000 (09:39 +0100)
commit12396e9300da9a3961eb47683cdd271445053979
tree47233c0c8b42d985a340bbf45c82952ef6e9e199
parent0c4e4d2ccb88299a7b11bb56905292c00f68f9ee
ASoC: mchp-spdifrx: fix return value in case completion times out

[ Upstream commit a4c4161d6eae3ef5f486d1638ef452d9bc1376b0 ]

wait_for_completion_interruptible_timeout() returns 0 in case of
timeout. Check this into account when returning from function.

Fixes: ef265c55c1ac ("ASoC: mchp-spdifrx: add driver for SPDIF RX")
Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Link: https://lore.kernel.org/r/20230130120647.638049-3-claudiu.beznea@microchip.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
sound/soc/atmel/mchp-spdifrx.c