[PATCH v5 09/11] mm, fs, dax: handle layout changes to pinned dax mappings

2018-03-09 Thread Dan Williams
Background: get_user_pages() in the filesystem pins file backed memory pages for access by devices performing dma. However, it only pins the memory pages not the page-to-file offset association. If a file is truncated the pages are mapped out of the file and dma may continue indefinitely into a

[PATCH v5 09/11] mm, fs, dax: handle layout changes to pinned dax mappings

2018-03-09 Thread Dan Williams
Background: get_user_pages() in the filesystem pins file backed memory pages for access by devices performing dma. However, it only pins the memory pages not the page-to-file offset association. If a file is truncated the pages are mapped out of the file and dma may continue indefinitely into a