]> git.baikalelectronics.ru Git - kernel.git/commit
ALSA: pcm: Disable only control mmap for explicit appl_ptr sync
authorTakashi Iwai <tiwai@suse.de>
Tue, 27 Jun 2017 09:54:37 +0000 (11:54 +0200)
committerTakashi Iwai <tiwai@suse.de>
Tue, 27 Jun 2017 11:56:03 +0000 (13:56 +0200)
commit9158414c974497a302978a58ce01dac71de29c9f
treefc4cb31166644316033d0a8f350a0a2b83148839
parent6d389a332a154acedfa5615dc138fdfb76d642e3
ALSA: pcm: Disable only control mmap for explicit appl_ptr sync

Now that user-space (typically alsa-lib) can specify which protocol
version it supports, we can optimize the kernel code depending on the
reported protocol version.

In this patch, we change the previous hack for enforcing the appl_ptr
sync by disabling status/control mmap.  Instead of forcibly disabling
both mmaps, we disable only the control mmap when user-space declares
the supported protocol version new enough.  For older user-space,
still both PCM status and control mmaps are disabled when requested by
the driver due to the compatibility reason.

Reviewed-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/core/pcm_native.c