]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
ASoC: stm32: spdifrx: fix race condition in irq handler
authorOlivier Moysan <olivier.moysan@st.com>
Wed, 4 Dec 2019 15:43:32 +0000 (16:43 +0100)
committerKhalid Elmously <khalid.elmously@canonical.com>
Fri, 14 Feb 2020 05:29:37 +0000 (00:29 -0500)
commitf063c5e03b26b72f9b0e9fc11fb86f9251195a71
tree0f5b9b4cfaa4a777a0f65e049cca60a2a721d03e
parent6b6f099c8c13f85c31eb85c537d1d18d68ca67b9
ASoC: stm32: spdifrx: fix race condition in irq handler

BugLink: https://bugs.launchpad.net/bugs/1861934
commit 86e1956af4c863d653136fd6e5694adf2054dbaa upstream.

When snd_pcm_stop() is called in interrupt routine,
substream context may have already been released.
Add protection on substream context.

Fixes: 03e4d5d56fa5 ("ASoC: stm32: Add SPDIFRX support")
Signed-off-by: Olivier Moysan <olivier.moysan@st.com>
Link: https://lore.kernel.org/r/20191204154333.7152-3-olivier.moysan@st.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
sound/soc/stm/stm32_spdifrx.c