ALSA: line6: Don't handle PCM trigger for other cards

Otherwise it oopses.

Tested-by: Chris Rorvick <chris@rorvick.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Takashi Iwai 2015-01-19 15:11:17 +01:00
parent a019f5e8c5
commit 7d70c81cca

View File

@ -233,6 +233,8 @@ int snd_line6_trigger(struct snd_pcm_substream *substream, int cmd)
clear_bit(LINE6_INDEX_PREPARED, &line6pcm->flags); clear_bit(LINE6_INDEX_PREPARED, &line6pcm->flags);
snd_pcm_group_for_each_entry(s, substream) { snd_pcm_group_for_each_entry(s, substream) {
if (s->pcm->card != substream->pcm->card)
continue;
switch (s->stream) { switch (s->stream) {
case SNDRV_PCM_STREAM_PLAYBACK: case SNDRV_PCM_STREAM_PLAYBACK:
err = snd_line6_playback_trigger(line6pcm, cmd); err = snd_line6_playback_trigger(line6pcm, cmd);