Lines Matching refs:substream
174 static int snd_p16v_pcm_open_playback_channel(struct snd_pcm_substream *substream, int channel_id) in snd_p16v_pcm_open_playback_channel() argument
176 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_open_playback_channel()
179 struct snd_pcm_runtime *runtime = substream->runtime; in snd_p16v_pcm_open_playback_channel()
188 epcm->substream = substream; in snd_p16v_pcm_open_playback_channel()
214 runtime->sync.id32[0] = substream->pcm->card->number; in snd_p16v_pcm_open_playback_channel()
222 static int snd_p16v_pcm_open_capture_channel(struct snd_pcm_substream *substream, int channel_id) in snd_p16v_pcm_open_capture_channel() argument
224 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_open_capture_channel()
227 struct snd_pcm_runtime *runtime = substream->runtime; in snd_p16v_pcm_open_capture_channel()
236 epcm->substream = substream; in snd_p16v_pcm_open_capture_channel()
267 static int snd_p16v_pcm_close_playback(struct snd_pcm_substream *substream) in snd_p16v_pcm_close_playback() argument
269 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_close_playback()
272 emu->p16v_voices[substream->pcm->device - emu->p16v_device_offset].use = 0; in snd_p16v_pcm_close_playback()
278 static int snd_p16v_pcm_close_capture(struct snd_pcm_substream *substream) in snd_p16v_pcm_close_capture() argument
280 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_close_capture()
288 static int snd_p16v_pcm_open_playback_front(struct snd_pcm_substream *substream) in snd_p16v_pcm_open_playback_front() argument
290 return snd_p16v_pcm_open_playback_channel(substream, PCM_FRONT_CHANNEL); in snd_p16v_pcm_open_playback_front()
293 static int snd_p16v_pcm_open_capture(struct snd_pcm_substream *substream) in snd_p16v_pcm_open_capture() argument
296 return snd_p16v_pcm_open_capture_channel(substream, 0); in snd_p16v_pcm_open_capture()
300 static int snd_p16v_pcm_hw_params_playback(struct snd_pcm_substream *substream, in snd_p16v_pcm_hw_params_playback() argument
304 result = snd_pcm_lib_malloc_pages(substream, in snd_p16v_pcm_hw_params_playback()
310 static int snd_p16v_pcm_hw_params_capture(struct snd_pcm_substream *substream, in snd_p16v_pcm_hw_params_capture() argument
314 result = snd_pcm_lib_malloc_pages(substream, in snd_p16v_pcm_hw_params_capture()
321 static int snd_p16v_pcm_hw_free_playback(struct snd_pcm_substream *substream) in snd_p16v_pcm_hw_free_playback() argument
324 result = snd_pcm_lib_free_pages(substream); in snd_p16v_pcm_hw_free_playback()
329 static int snd_p16v_pcm_hw_free_capture(struct snd_pcm_substream *substream) in snd_p16v_pcm_hw_free_capture() argument
332 result = snd_pcm_lib_free_pages(substream); in snd_p16v_pcm_hw_free_capture()
338 static int snd_p16v_pcm_prepare_playback(struct snd_pcm_substream *substream) in snd_p16v_pcm_prepare_playback() argument
340 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_prepare_playback()
341 struct snd_pcm_runtime *runtime = substream->runtime; in snd_p16v_pcm_prepare_playback()
342 int channel = substream->pcm->device - emu->p16v_device_offset; in snd_p16v_pcm_prepare_playback()
400 static int snd_p16v_pcm_prepare_capture(struct snd_pcm_substream *substream) in snd_p16v_pcm_prepare_capture() argument
402 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_prepare_capture()
403 struct snd_pcm_runtime *runtime = substream->runtime; in snd_p16v_pcm_prepare_capture()
404 int channel = substream->pcm->device - emu->p16v_device_offset; in snd_p16v_pcm_prepare_capture()
465 static int snd_p16v_pcm_trigger_playback(struct snd_pcm_substream *substream, in snd_p16v_pcm_trigger_playback() argument
468 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_trigger_playback()
487 snd_pcm_group_for_each_entry(s, substream) { in snd_p16v_pcm_trigger_playback()
493 channel = substream->pcm->device-emu->p16v_device_offset; in snd_p16v_pcm_trigger_playback()
498 snd_pcm_trigger_done(s, substream); in snd_p16v_pcm_trigger_playback()
519 static int snd_p16v_pcm_trigger_capture(struct snd_pcm_substream *substream, in snd_p16v_pcm_trigger_capture() argument
522 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_trigger_capture()
523 struct snd_pcm_runtime *runtime = substream->runtime; in snd_p16v_pcm_trigger_capture()
550 snd_p16v_pcm_pointer_playback(struct snd_pcm_substream *substream) in snd_p16v_pcm_pointer_playback() argument
552 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_pointer_playback()
553 struct snd_pcm_runtime *runtime = substream->runtime; in snd_p16v_pcm_pointer_playback()
556 int channel = substream->pcm->device - emu->p16v_device_offset; in snd_p16v_pcm_pointer_playback()
575 snd_p16v_pcm_pointer_capture(struct snd_pcm_substream *substream) in snd_p16v_pcm_pointer_capture() argument
577 struct snd_emu10k1 *emu = snd_pcm_substream_chip(substream); in snd_p16v_pcm_pointer_capture()
578 struct snd_pcm_runtime *runtime = substream->runtime; in snd_p16v_pcm_pointer_capture()
643 struct snd_pcm_substream *substream; in snd_p16v_pcm() local
664 for(substream = pcm->streams[SNDRV_PCM_STREAM_PLAYBACK].substream; in snd_p16v_pcm()
665 substream; in snd_p16v_pcm()
666 substream = substream->next) { in snd_p16v_pcm()
667 if ((err = snd_pcm_lib_preallocate_pages(substream, in snd_p16v_pcm()
678 for (substream = pcm->streams[SNDRV_PCM_STREAM_CAPTURE].substream; in snd_p16v_pcm()
679 substream; in snd_p16v_pcm()
680 substream = substream->next) { in snd_p16v_pcm()
681 if ((err = snd_pcm_lib_preallocate_pages(substream, in snd_p16v_pcm()