aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/pci/pcxhr/pcxhr.c23
1 files changed, 11 insertions, 12 deletions
diff --git a/sound/pci/pcxhr/pcxhr.c b/sound/pci/pcxhr/pcxhr.c
index e1bdeed3a465..f7f6a687f033 100644
--- a/sound/pci/pcxhr/pcxhr.c
+++ b/sound/pci/pcxhr/pcxhr.c
@@ -639,19 +639,21 @@ static int pcxhr_trigger(struct snd_pcm_substream *subs, int cmd)
639{ 639{
640 struct pcxhr_stream *stream; 640 struct pcxhr_stream *stream;
641 struct snd_pcm_substream *s; 641 struct snd_pcm_substream *s;
642 int i;
643 642
644 switch (cmd) { 643 switch (cmd) {
645 case SNDRV_PCM_TRIGGER_START: 644 case SNDRV_PCM_TRIGGER_START:
646 snd_printdd("SNDRV_PCM_TRIGGER_START\n"); 645 snd_printdd("SNDRV_PCM_TRIGGER_START\n");
647 i = 0; 646 if (snd_pcm_stream_linked(subs)) {
648 snd_pcm_group_for_each_entry(s, subs) { 647 struct snd_pcxhr *chip = snd_pcm_substream_chip(subs);
649 stream = s->runtime->private_data; 648 snd_pcm_group_for_each_entry(s, subs) {
650 stream->status = PCXHR_STREAM_STATUS_SCHEDULE_RUN; 649 stream = s->runtime->private_data;
651 snd_pcm_trigger_done(s, subs); 650 stream->status =
652 i++; 651 PCXHR_STREAM_STATUS_SCHEDULE_RUN;
653 } 652 snd_pcm_trigger_done(s, subs);
654 if (i==1) { 653 }
654 tasklet_hi_schedule(&chip->mgr->trigger_taskq);
655 } else {
656 stream = subs->runtime->private_data;
655 snd_printdd("Only one Substream %c %d\n", 657 snd_printdd("Only one Substream %c %d\n",
656 stream->pipe->is_capture ? 'C' : 'P', 658 stream->pipe->is_capture ? 'C' : 'P',
657 stream->pipe->first_audio); 659 stream->pipe->first_audio);
@@ -663,9 +665,6 @@ static int pcxhr_trigger(struct snd_pcm_substream *subs, int cmd)
663 if (pcxhr_set_stream_state(stream)) 665 if (pcxhr_set_stream_state(stream))
664 return -EINVAL; 666 return -EINVAL;
665 stream->status = PCXHR_STREAM_STATUS_RUNNING; 667 stream->status = PCXHR_STREAM_STATUS_RUNNING;
666 } else {
667 struct snd_pcxhr *chip = snd_pcm_substream_chip(subs);
668 tasklet_hi_schedule(&chip->mgr->trigger_taskq);
669 } 668 }
670 break; 669 break;
671 case SNDRV_PCM_TRIGGER_STOP: 670 case SNDRV_PCM_TRIGGER_STOP: