Lines Matching refs:substream
20 #define snd_pcm_substream_chip(substream) ((substream)->private_data) argument
53 int (*open)(struct snd_pcm_substream *substream);
54 int (*close)(struct snd_pcm_substream *substream);
55 int (*ioctl)(struct snd_pcm_substream * substream,
57 int (*hw_params)(struct snd_pcm_substream *substream,
59 int (*hw_free)(struct snd_pcm_substream *substream);
60 int (*prepare)(struct snd_pcm_substream *substream);
61 int (*trigger)(struct snd_pcm_substream *substream, int cmd);
62 snd_pcm_uframes_t (*pointer)(struct snd_pcm_substream *substream);
63 int (*get_time_info)(struct snd_pcm_substream *substream,
67 int (*fill_silence)(struct snd_pcm_substream *substream, int channel,
69 int (*copy_user)(struct snd_pcm_substream *substream, int channel,
72 int (*copy_kernel)(struct snd_pcm_substream *substream, int channel,
74 struct page *(*page)(struct snd_pcm_substream *substream,
76 int (*mmap)(struct snd_pcm_substream *substream, struct vm_area_struct *vma);
77 int (*ack)(struct snd_pcm_substream *substream);
218 struct snd_pcm_substream *substream; member
480 #define SUBSTREAM_BUSY(substream) ((substream)->ref_count > 0) argument
489 struct snd_pcm_substream *substream; member
554 int snd_pcm_info(struct snd_pcm_substream *substream, struct snd_pcm_info *info);
555 int snd_pcm_info_user(struct snd_pcm_substream *substream,
557 int snd_pcm_status(struct snd_pcm_substream *substream,
559 int snd_pcm_start(struct snd_pcm_substream *substream);
560 int snd_pcm_stop(struct snd_pcm_substream *substream, snd_pcm_state_t status);
561 int snd_pcm_drain_done(struct snd_pcm_substream *substream);
562 int snd_pcm_stop_xrun(struct snd_pcm_substream *substream);
571 int snd_pcm_kernel_ioctl(struct snd_pcm_substream *substream, unsigned int cmd, void *arg);
574 void snd_pcm_release_substream(struct snd_pcm_substream *substream);
577 void snd_pcm_detach_substream(struct snd_pcm_substream *substream);
578 int snd_pcm_mmap_data(struct snd_pcm_substream *substream, struct file *file, struct vm_area_struct…
582 void snd_pcm_debug_name(struct snd_pcm_substream *substream,
586 snd_pcm_debug_name(struct snd_pcm_substream *substream, char *buf, size_t size) in snd_pcm_debug_name() argument
602 static inline int snd_pcm_stream_linked(struct snd_pcm_substream *substream) in snd_pcm_stream_linked() argument
604 return substream->group != &substream->self_group; in snd_pcm_stream_linked()
607 void snd_pcm_stream_lock(struct snd_pcm_substream *substream);
608 void snd_pcm_stream_unlock(struct snd_pcm_substream *substream);
609 void snd_pcm_stream_lock_irq(struct snd_pcm_substream *substream);
610 void snd_pcm_stream_unlock_irq(struct snd_pcm_substream *substream);
611 unsigned long _snd_pcm_stream_lock_irqsave(struct snd_pcm_substream *substream);
622 #define snd_pcm_stream_lock_irqsave(substream, flags) \ argument
625 flags = _snd_pcm_stream_lock_irqsave(substream); \
627 void snd_pcm_stream_unlock_irqrestore(struct snd_pcm_substream *substream,
639 #define snd_pcm_group_for_each_entry(s, substream) \ argument
640 list_for_each_entry(s, &substream->group->substreams, link_list)
649 static inline int snd_pcm_running(struct snd_pcm_substream *substream) in snd_pcm_running() argument
651 return (substream->runtime->status->state == SNDRV_PCM_STATE_RUNNING || in snd_pcm_running()
652 (substream->runtime->status->state == SNDRV_PCM_STATE_DRAINING && in snd_pcm_running()
653 substream->stream == SNDRV_PCM_STREAM_PLAYBACK)); in snd_pcm_running()
710 static inline size_t snd_pcm_lib_buffer_bytes(struct snd_pcm_substream *substream) in snd_pcm_lib_buffer_bytes() argument
712 struct snd_pcm_runtime *runtime = substream->runtime; in snd_pcm_lib_buffer_bytes()
720 static inline size_t snd_pcm_lib_period_bytes(struct snd_pcm_substream *substream) in snd_pcm_lib_period_bytes() argument
722 struct snd_pcm_runtime *runtime = substream->runtime; in snd_pcm_lib_period_bytes()
782 static inline int snd_pcm_playback_ready(struct snd_pcm_substream *substream) in snd_pcm_playback_ready() argument
784 struct snd_pcm_runtime *runtime = substream->runtime; in snd_pcm_playback_ready()
796 static inline int snd_pcm_capture_ready(struct snd_pcm_substream *substream) in snd_pcm_capture_ready() argument
798 struct snd_pcm_runtime *runtime = substream->runtime; in snd_pcm_capture_ready()
811 static inline int snd_pcm_playback_data(struct snd_pcm_substream *substream) in snd_pcm_playback_data() argument
813 struct snd_pcm_runtime *runtime = substream->runtime; in snd_pcm_playback_data()
828 static inline int snd_pcm_playback_empty(struct snd_pcm_substream *substream) in snd_pcm_playback_empty() argument
830 struct snd_pcm_runtime *runtime = substream->runtime; in snd_pcm_playback_empty()
842 static inline int snd_pcm_capture_empty(struct snd_pcm_substream *substream) in snd_pcm_capture_empty() argument
844 struct snd_pcm_runtime *runtime = substream->runtime; in snd_pcm_capture_empty()
862 static inline void snd_pcm_trigger_done(struct snd_pcm_substream *substream, in snd_pcm_trigger_done() argument
865 substream->runtime->trigger_master = master; in snd_pcm_trigger_done()
970 int snd_pcm_hw_refine(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params);
1056 void snd_pcm_set_sync(struct snd_pcm_substream *substream);
1057 int snd_pcm_lib_ioctl(struct snd_pcm_substream *substream,
1059 void snd_pcm_period_elapsed(struct snd_pcm_substream *substream);
1060 snd_pcm_sframes_t __snd_pcm_lib_xfer(struct snd_pcm_substream *substream,
1065 snd_pcm_lib_write(struct snd_pcm_substream *substream, in snd_pcm_lib_write() argument
1068 return __snd_pcm_lib_xfer(substream, (void __force *)buf, true, frames, false); in snd_pcm_lib_write()
1072 snd_pcm_lib_read(struct snd_pcm_substream *substream, in snd_pcm_lib_read() argument
1075 return __snd_pcm_lib_xfer(substream, (void __force *)buf, true, frames, false); in snd_pcm_lib_read()
1079 snd_pcm_lib_writev(struct snd_pcm_substream *substream, in snd_pcm_lib_writev() argument
1082 return __snd_pcm_lib_xfer(substream, (void *)bufs, false, frames, false); in snd_pcm_lib_writev()
1086 snd_pcm_lib_readv(struct snd_pcm_substream *substream, in snd_pcm_lib_readv() argument
1089 return __snd_pcm_lib_xfer(substream, (void *)bufs, false, frames, false); in snd_pcm_lib_readv()
1093 snd_pcm_kernel_write(struct snd_pcm_substream *substream, in snd_pcm_kernel_write() argument
1096 return __snd_pcm_lib_xfer(substream, (void *)buf, true, frames, true); in snd_pcm_kernel_write()
1100 snd_pcm_kernel_read(struct snd_pcm_substream *substream, in snd_pcm_kernel_read() argument
1103 return __snd_pcm_lib_xfer(substream, buf, true, frames, true); in snd_pcm_kernel_read()
1107 snd_pcm_kernel_writev(struct snd_pcm_substream *substream, in snd_pcm_kernel_writev() argument
1110 return __snd_pcm_lib_xfer(substream, bufs, false, frames, true); in snd_pcm_kernel_writev()
1114 snd_pcm_kernel_readv(struct snd_pcm_substream *substream, in snd_pcm_kernel_readv() argument
1117 return __snd_pcm_lib_xfer(substream, bufs, false, frames, true); in snd_pcm_kernel_readv()
1136 static inline void snd_pcm_set_runtime_buffer(struct snd_pcm_substream *substream, in snd_pcm_set_runtime_buffer() argument
1139 struct snd_pcm_runtime *runtime = substream->runtime; in snd_pcm_set_runtime_buffer()
1178 void snd_pcm_lib_preallocate_free(struct snd_pcm_substream *substream);
1180 void snd_pcm_lib_preallocate_pages(struct snd_pcm_substream *substream,
1186 int snd_pcm_lib_malloc_pages(struct snd_pcm_substream *substream, size_t size);
1187 int snd_pcm_lib_free_pages(struct snd_pcm_substream *substream);
1189 int _snd_pcm_lib_alloc_vmalloc_buffer(struct snd_pcm_substream *substream,
1191 int snd_pcm_lib_free_vmalloc_buffer(struct snd_pcm_substream *substream);
1192 struct page *snd_pcm_lib_get_vmalloc_page(struct snd_pcm_substream *substream,
1207 (struct snd_pcm_substream *substream, size_t size) in snd_pcm_lib_alloc_vmalloc_buffer() argument
1209 return _snd_pcm_lib_alloc_vmalloc_buffer(substream, size, in snd_pcm_lib_alloc_vmalloc_buffer()
1225 (struct snd_pcm_substream *substream, size_t size) in snd_pcm_lib_alloc_vmalloc_32_buffer() argument
1227 return _snd_pcm_lib_alloc_vmalloc_buffer(substream, size, in snd_pcm_lib_alloc_vmalloc_32_buffer()
1231 #define snd_pcm_get_dma_buf(substream) ((substream)->runtime->dma_buffer_p) argument
1237 #define snd_pcm_substream_sgbuf(substream) \ argument
1238 snd_pcm_get_dma_buf(substream)->private_data
1240 struct page *snd_pcm_sgbuf_ops_page(struct snd_pcm_substream *substream,
1255 snd_pcm_sgbuf_get_addr(struct snd_pcm_substream *substream, unsigned int ofs) in snd_pcm_sgbuf_get_addr() argument
1257 return snd_sgbuf_get_addr(snd_pcm_get_dma_buf(substream), ofs); in snd_pcm_sgbuf_get_addr()
1266 snd_pcm_sgbuf_get_ptr(struct snd_pcm_substream *substream, unsigned int ofs) in snd_pcm_sgbuf_get_ptr() argument
1268 return snd_sgbuf_get_ptr(snd_pcm_get_dma_buf(substream), ofs); in snd_pcm_sgbuf_get_ptr()
1279 snd_pcm_sgbuf_get_chunk_size(struct snd_pcm_substream *substream, in snd_pcm_sgbuf_get_chunk_size() argument
1282 return snd_sgbuf_get_chunk_size(snd_pcm_get_dma_buf(substream), ofs, size); in snd_pcm_sgbuf_get_chunk_size()
1293 struct snd_pcm_substream *substream = (struct snd_pcm_substream *)area->vm_private_data; in snd_pcm_mmap_data_open() local
1294 atomic_inc(&substream->mmap_count); in snd_pcm_mmap_data_open()
1305 struct snd_pcm_substream *substream = (struct snd_pcm_substream *)area->vm_private_data; in snd_pcm_mmap_data_close() local
1306 atomic_dec(&substream->mmap_count); in snd_pcm_mmap_data_close()
1309 int snd_pcm_lib_default_mmap(struct snd_pcm_substream *substream,
1314 int snd_pcm_lib_mmap_iomem(struct snd_pcm_substream *substream, struct vm_area_struct *area);
1349 static inline const char *snd_pcm_stream_str(struct snd_pcm_substream *substream) in snd_pcm_stream_str() argument
1351 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) in snd_pcm_stream_str()
1386 for (s = info->pcm->streams[info->stream].substream; s; s = s->next) in snd_pcm_chmap_substream()