linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 0/5] mm/gup: Introduce pin_user_pages_fd() for pinning shmem/hugetlbfs file pages (v4)
@ 2023-11-18  6:32 Vivek Kasireddy
  2023-11-18  6:32 ` [PATCH v4 1/5] udmabuf: Use vmf_insert_pfn and VM_PFNMAP for handling mmap Vivek Kasireddy
                   ` (4 more replies)
  0 siblings, 5 replies; 8+ messages in thread
From: Vivek Kasireddy @ 2023-11-18  6:32 UTC (permalink / raw)
  To: dri-devel, linux-mm
  Cc: Vivek Kasireddy, David Hildenbrand, Daniel Vetter, Mike Kravetz,
	Hugh Dickins, Peter Xu, Jason Gunthorpe, Gerd Hoffmann,
	Dongwon Kim, Junxiao Chang

The first two patches were previously reviewed but not yet merged.
These ones need to be merged first as the fourth patch depends on
the changes introduced in them and they also fix bugs seen in
very specific scenarios (running Qemu with hugetlb=on, blob=true
and rebooting guest VM).

The third patch introduces pin_user_pages_fd() API and the fourth
patch shows how the udmabuf driver can make use of it to
longterm-pin the the pages. The last patch adds two new udmabuf
selftests to verify data coherency after potential page migration.

v2:
- Updated the first patch to include review feedback from David and
  Jason. The main change in this series is the allocation of page
  in the case of hugetlbfs if it is not found in the page cache.

v3:
- Made changes to include review feedback from David to improve the
  comments and readability of code
- Enclosed the hugepage alloc code with #ifdef CONFIG_HUGETLB_PAGE

v4:
- Augmented the commit message of the udmabuf patch that uses
  pin_user_pages_fd()
- Added previously reviewed but unmerged udmabuf patches to this
  series

Cc: David Hildenbrand <david@redhat.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Mike Kravetz <mike.kravetz@oracle.com>
Cc: Hugh Dickins <hughd@google.com>
Cc: Peter Xu <peterx@redhat.com>
Cc: Jason Gunthorpe <jgg@nvidia.com>
Cc: Gerd Hoffmann <kraxel@redhat.com>
Cc: Dongwon Kim <dongwon.kim@intel.com>
Cc: Junxiao Chang <junxiao.chang@intel.com>

Vivek Kasireddy (5):
  udmabuf: Use vmf_insert_pfn and VM_PFNMAP for handling mmap
  udmabuf: Add back support for mapping hugetlb pages (v3)
  mm/gup: Introduce pin_user_pages_fd() for pinning shmem/hugetlbfs file
    pages (v4)
  udmabuf: Pin the pages using pin_user_pages_fd() API (v3)
  selftests/dma-buf/udmabuf: Add tests to verify data after page
    migration

 drivers/dma-buf/udmabuf.c                     |  96 ++++++++---
 include/linux/mm.h                            |   2 +
 mm/gup.c                                      | 108 +++++++++++++
 .../selftests/drivers/dma-buf/udmabuf.c       | 151 +++++++++++++++++-
 4 files changed, 328 insertions(+), 29 deletions(-)

-- 
2.39.2



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2023-11-21  6:55 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-18  6:32 [PATCH v4 0/5] mm/gup: Introduce pin_user_pages_fd() for pinning shmem/hugetlbfs file pages (v4) Vivek Kasireddy
2023-11-18  6:32 ` [PATCH v4 1/5] udmabuf: Use vmf_insert_pfn and VM_PFNMAP for handling mmap Vivek Kasireddy
2023-11-18  6:32 ` [PATCH v4 2/5] udmabuf: Add back support for mapping hugetlb pages (v3) Vivek Kasireddy
2023-11-18  6:32 ` [PATCH v4 3/5] mm/gup: Introduce pin_user_pages_fd() for pinning shmem/hugetlbfs file pages (v4) Vivek Kasireddy
2023-11-20  8:48   ` David Hildenbrand
2023-11-21  6:54     ` Kasireddy, Vivek
2023-11-18  6:32 ` [PATCH v4 4/5] udmabuf: Pin the pages using pin_user_pages_fd() API (v3) Vivek Kasireddy
2023-11-18  6:32 ` [PATCH v4 5/5] selftests/dma-buf/udmabuf: Add tests to verify data after page migration Vivek Kasireddy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox