Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 305806
b: refs/heads/master
c: 97f8d3b
h: refs/heads/master
v: v3
  • Loading branch information
Daniel Mack authored and Takashi Iwai committed May 21, 2012
1 parent 7c26e81 commit 26e6bab
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4f7c39dc557cabdbc932ae83432cc225c480133c
refs/heads/master: 97f8d3b6503082416898f893a442a78f8819c42a
12 changes: 12 additions & 0 deletions trunk/sound/usb/pcm.c
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,11 @@ static int snd_usb_hw_params(struct snd_pcm_substream *substream,
mutex_unlock(&subs->stream->chip->shutdown_mutex);
}

if (ret == 0) {
subs->interface = fmt->iface;
subs->altset_idx = fmt->altset_idx;
}

return ret;
}

Expand Down Expand Up @@ -1123,13 +1128,16 @@ static int snd_usb_substream_playback_trigger(struct snd_pcm_substream *substrea
case SNDRV_PCM_TRIGGER_PAUSE_RELEASE:
subs->data_endpoint->prepare_data_urb = prepare_playback_urb;
subs->data_endpoint->retire_data_urb = retire_playback_urb;
subs->running = 1;
return 0;
case SNDRV_PCM_TRIGGER_STOP:
stop_endpoints(subs, 0, 0, 0);
subs->running = 0;
return 0;
case SNDRV_PCM_TRIGGER_PAUSE_PUSH:
subs->data_endpoint->prepare_data_urb = NULL;
subs->data_endpoint->retire_data_urb = NULL;
subs->running = 0;
return 0;
}

Expand All @@ -1148,15 +1156,19 @@ int snd_usb_substream_capture_trigger(struct snd_pcm_substream *substream, int c
return err;

subs->data_endpoint->retire_data_urb = retire_capture_urb;
subs->running = 1;
return 0;
case SNDRV_PCM_TRIGGER_STOP:
stop_endpoints(subs, 0, 0, 0);
subs->running = 0;
return 0;
case SNDRV_PCM_TRIGGER_PAUSE_PUSH:
subs->data_endpoint->retire_data_urb = NULL;
subs->running = 0;
return 0;
case SNDRV_PCM_TRIGGER_PAUSE_RELEASE:
subs->data_endpoint->retire_data_urb = retire_capture_urb;
subs->running = 1;
return 0;
}

Expand Down

0 comments on commit 26e6bab

Please sign in to comment.