alsa-lib: mmap API disables blocking I/O or sw_params
28 May
2020
28 May
'20
12:14 a.m.
I'm swapping out a vanilla loop based on RW_INTERLEAVED for MMAP_INTERLEAVED, to reduce memory copies:
The equivalent code becomes:
snd_pcm_avail_update() snd_pcm_mmap_begin() snd_pcm_mmap_commit()
but what I find no longer works:
* Blocking I/O: it's necessary to make explicit calls to snd_pcm_wait() with syscall overhead of poll()
* Automatic start (and perhaps others): so I have to count the frames committed and call snd_pcm_start() explicitly.
I don't think these are conceptually incompatible with mmap, so is this the intended behaviour and an important omission from the docs? Or is the mmap API not widely used and I'm stumbling on bugs?
--
Mark
1670
Age (days ago)
1670
Last active (days ago)
0 comments
1 participants
participants (1)
-
Mark Hills