[alsa-devel] [PATCH 0/2] ALSA: pcm: implement the anonymous dup v3

Mark Brown broonie at kernel.org
Fri Feb 1 13:59:43 CET 2019


On Thu, Jan 31, 2019 at 09:32:27PM +0100, Takashi Iwai wrote:
> On Thu, 31 Jan 2019 20:54:33 +0100,
> Zach Riggle 🖖 wrote:

> > (1) Can the buffer be mremap()ed with a different offset into the buffer? 
> > This was a concern in the past and the reason for the anon_inode stuff at
> > all.  I believe that as long as the *size* of the mapping doesn't change,
> > Linux mm will gladly permit mremap() without informing the driver.

> Could you elaborate which perspective of mremap() can be a big
> problem?  The driver interface does nothing but a standard mmap for
> now.

I believe the issue was that if someone could remap the buffer to gain
access to memory outside the memory allocated for the PCM buffer that
would be a problem.  To be honest I'm surprised that this might be a
general issue with mmap().
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20190201/7cba6ad7/attachment.sig>


More information about the Alsa-devel mailing list