Lines Matching refs:sync_ptr
399 struct snd_pcm_sync_ptr *sync_ptr = pcm->sync_ptr; in pcm_avail() local
402 sync_ptr->s.status.hw_ptr, in pcm_avail()
404 sync_ptr->c.control.appl_ptr); in pcm_avail()
407 long avail = sync_ptr->s.status.hw_ptr - sync_ptr->c.control.appl_ptr; in pcm_avail()
412 …long avail = sync_ptr->s.status.hw_ptr - sync_ptr->c.control.appl_ptr + ((pcm->flags & PCM_MONO) ?… in pcm_avail()
421 int sync_ptr(struct pcm *pcm) in sync_ptr() function
424 err = ioctl(pcm->fd, SNDRV_PCM_IOCTL_SYNC_PTR, pcm->sync_ptr); in sync_ptr()
462 struct snd_pcm_sync_ptr *sync_ptr = pcm->sync_ptr; in dst_address() local
465 …appl_ptr = (pcm->flags & PCM_MONO) ? sync_ptr->c.control.appl_ptr*2 : sync_ptr->c.control.appl_ptr… in dst_address()
474 struct snd_pcm_sync_ptr *sync_ptr = pcm->sync_ptr; in mmap_transfer() local
495 struct snd_pcm_sync_ptr *sync_ptr = pcm->sync_ptr; in mmap_transfer_capture() local
501 …unsigned int tmp = (pcm->flags & PCM_MONO) ? sync_ptr->c.control.appl_ptr*2 : sync_ptr->c.control.… in mmap_transfer_capture()
534 pcm->sync_ptr->flags = SNDRV_PCM_SYNC_PTR_APPL | SNDRV_PCM_SYNC_PTR_AVAIL_MIN; in pcm_write_mmap()
535 err = sync_ptr(pcm); in pcm_write_mmap()
543 pcm->sync_ptr->c.control.appl_ptr += frames; in pcm_write_mmap()
544 pcm->sync_ptr->flags = 0; in pcm_write_mmap()
546 err = sync_ptr(pcm); in pcm_write_mmap()
554 bytes_written = pcm->sync_ptr->c.control.appl_ptr - pcm->sync_ptr->s.status.hw_ptr; in pcm_write_mmap()
750 if (pcm->sync_ptr) in pcm_close()
751 free(pcm->sync_ptr); in pcm_close()
815 pcm->sync_ptr = calloc(1, sizeof(struct snd_pcm_sync_ptr)); in pcm_open()
816 if (!pcm->sync_ptr) { in pcm_open()
824 free(pcm->sync_ptr); in pcm_open()
833 free(pcm->sync_ptr); in pcm_open()