summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2013-07-11 18:02:38 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-07-25 14:07:42 -0700
commitdf3b055c92883b04459c54888b4bbb169ccb1b62 (patch)
tree6c6bb6870215e959197669a9cbf3d9631d5eb559 /drivers
parentd6d10b1dceba6ed2b3d74207b2a454c2f4427785 (diff)
downloadlwn-df3b055c92883b04459c54888b4bbb169ccb1b62.tar.gz
lwn-df3b055c92883b04459c54888b4bbb169ccb1b62.zip
staging: line6: Fix unlocked snd_pcm_stop() call
commit 86f0b5b86d142b9323432fef078a6cf0fb5dda74 upstream. snd_pcm_stop() must be called in the PCM substream lock context. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/line6/pcm.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/staging/line6/pcm.c b/drivers/staging/line6/pcm.c
index 02f77d74809f..a7856bad3cc6 100644
--- a/drivers/staging/line6/pcm.c
+++ b/drivers/staging/line6/pcm.c
@@ -385,8 +385,11 @@ static int snd_line6_pcm_free(struct snd_device *device)
*/
static void pcm_disconnect_substream(struct snd_pcm_substream *substream)
{
- if (substream->runtime && snd_pcm_running(substream))
+ if (substream->runtime && snd_pcm_running(substream)) {
+ snd_pcm_stream_lock_irq(substream);
snd_pcm_stop(substream, SNDRV_PCM_STATE_DISCONNECTED);
+ snd_pcm_stream_unlock_irq(substream);
+ }
}
/*