diff options
author | Clemens Ladisch <clemens@ladisch.de> | 2007-07-30 02:14:31 -0400 |
---|---|---|
committer | Jaroslav Kysela <perex@perex.cz> | 2007-10-16 09:58:13 -0400 |
commit | 29998d24ab5ec488cd127488246cc749b0ac52d6 (patch) | |
tree | bef33b79ed8c45f88c73871694418f563deaa10b /sound/pci/pcxhr | |
parent | 82467611ffc41fba534c95f8b4ae3887a90f5a66 (diff) |
[ALSA] check for linked substreams of different cards
It is possible to have linked substreams that belong to different cards
and/or different drivers. This patch changes some drivers to make sure
that they do not incorrectly try to handle substreams of a different
card.
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Diffstat (limited to 'sound/pci/pcxhr')
-rw-r--r-- | sound/pci/pcxhr/pcxhr.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/pci/pcxhr/pcxhr.c b/sound/pci/pcxhr/pcxhr.c index f7f6a687f033..1b787f455576 100644 --- a/sound/pci/pcxhr/pcxhr.c +++ b/sound/pci/pcxhr/pcxhr.c | |||
@@ -646,6 +646,8 @@ static int pcxhr_trigger(struct snd_pcm_substream *subs, int cmd) | |||
646 | if (snd_pcm_stream_linked(subs)) { | 646 | if (snd_pcm_stream_linked(subs)) { |
647 | struct snd_pcxhr *chip = snd_pcm_substream_chip(subs); | 647 | struct snd_pcxhr *chip = snd_pcm_substream_chip(subs); |
648 | snd_pcm_group_for_each_entry(s, subs) { | 648 | snd_pcm_group_for_each_entry(s, subs) { |
649 | if (snd_pcm_substream_chip(s) != chip) | ||
650 | continue; | ||
649 | stream = s->runtime->private_data; | 651 | stream = s->runtime->private_data; |
650 | stream->status = | 652 | stream->status = |
651 | PCXHR_STREAM_STATUS_SCHEDULE_RUN; | 653 | PCXHR_STREAM_STATUS_SCHEDULE_RUN; |