ALSA: pcm: Use dma_mmap_coherent() on x86, too
authorTakashi Iwai <tiwai@suse.de>
Mon, 15 Jun 2020 16:00:42 +0000 (18:00 +0200)
committerTakashi Iwai <tiwai@suse.de>
Mon, 15 Jun 2020 16:01:27 +0000 (18:01 +0200)
commitd955dab33af4ebff0f6c486da216ebbf590eb7e4
tree7add5c9e75462ef1f5d13040088a360afbe81619
parentb3a9e3b9622ae10064826dccb4f7a52bd88c7407
ALSA: pcm: Use dma_mmap_coherent() on x86, too

We avoided the explicit use of dma_mmap_coherent() on x86 because of a
spurious warning in x86 APT code in the past.  However, this blindly
assumes that the pages allocated via dma_alloc_coherent() on x86 are
the ones convertible via virt_to_page() (that is used in the default
mmap handler), and it's no longer true; with the indirect DMA ops,
this can be handled differently.  The only certain way for doing mmap
such pages is the dma_mmap_coherent(), and the warning seems already
gone in the recent code, so let's use it consistently.

Link: https://lore.kernel.org/r/20200615160045.2703-2-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/core/pcm_native.c