Skip to content

Commit

Permalink
ALSA: asihpi: Fix unlocked snd_pcm_stop() call
Browse files Browse the repository at this point in the history
snd_pcm_stop() must be called in the PCM substream lock context.

Cc: <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
  • Loading branch information
tiwai committed Jul 15, 2013
1 parent 1abfeb0 commit 6047829
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions sound/pci/asihpi/asihpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -769,7 +769,10 @@ static void snd_card_asihpi_timer_function(unsigned long data)
s->number);
ds->drained_count++;
if (ds->drained_count > 20) {
unsigned long flags;
snd_pcm_stream_lock_irqsave(s, flags);
snd_pcm_stop(s, SNDRV_PCM_STATE_XRUN);
snd_pcm_stream_unlock_irqrestore(s, flags);
continue;
}
} else {
Expand Down

0 comments on commit 6047829

Please sign in to comment.