All of lore.kernel.org
 help / color / mirror / Atom feed
* start sorting out the ZONE_DEVICE refcount mess v2
@ 2022-02-10  7:28 ` Christoph Hellwig
  0 siblings, 0 replies; 114+ messages in thread
From: Christoph Hellwig @ 2022-02-10  7:28 UTC (permalink / raw)
  To: Andrew Morton, Dan Williams
  Cc: Felix Kuehling, Alex Deucher, Christian König, Pan, Xinhui,
	Ben Skeggs, Karol Herbst, Lyude Paul, Jason Gunthorpe,
	Alistair Popple, Logan Gunthorpe, Ralph Campbell, linux-kernel,
	amd-gfx, dri-devel, nouveau, nvdimm, linux-mm

Hi all,

this series removes the offset by one refcount for ZONE_DEVICE pages
that are freed back to the driver owning them, which is just device
private ones for now, but also the planned device coherent pages
and the ehanced p2p ones pending.

It does not address the fsdax pages yet, which will be attacked in a
follow on series.

Note that if we want to get the p2p series rebased on top of this
we'll need a git branch for this series.  I could offer to host one.

A git tree is available here:

    git://git.infradead.org/users/hch/misc.git pgmap-refcount

Gitweb:

    http://git.infradead.org/users/hch/misc.git/shortlog/refs/heads/pgmap-refcount

Changes since v1:
 - add a missing memremap.h include in memcontrol.c
 - include rebased versions of the device coherent support and
   device coherent migration support series as well as additional
   cleanup patches

Diffstt:
 arch/arm64/mm/mmu.c                      |    1 
 arch/powerpc/kvm/book3s_hv_uvmem.c       |    1 
 drivers/gpu/drm/amd/amdkfd/kfd_migrate.c |   35 -
 drivers/gpu/drm/amd/amdkfd/kfd_priv.h    |    1 
 drivers/gpu/drm/drm_cache.c              |    2 
 drivers/gpu/drm/nouveau/nouveau_dmem.c   |    3 
 drivers/gpu/drm/nouveau/nouveau_svm.c    |    1 
 drivers/infiniband/core/rw.c             |    1 
 drivers/nvdimm/pmem.h                    |    1 
 drivers/nvme/host/pci.c                  |    1 
 drivers/nvme/target/io-cmd-bdev.c        |    1 
 fs/Kconfig                               |    2 
 fs/fuse/virtio_fs.c                      |    1 
 include/linux/hmm.h                      |    9 
 include/linux/memremap.h                 |   36 +
 include/linux/migrate.h                  |    1 
 include/linux/mm.h                       |   59 --
 lib/test_hmm.c                           |  353 ++++++++++---
 lib/test_hmm_uapi.h                      |   22 
 mm/Kconfig                               |    7 
 mm/Makefile                              |    1 
 mm/gup.c                                 |  127 +++-
 mm/internal.h                            |    3 
 mm/memcontrol.c                          |   19 
 mm/memory-failure.c                      |    8 
 mm/memremap.c                            |   75 +-
 mm/migrate.c                             |  763 ----------------------------
 mm/migrate_device.c                      |  822 +++++++++++++++++++++++++++++++
 mm/rmap.c                                |    5 
 mm/swap.c                                |   49 -
 tools/testing/selftests/vm/Makefile      |    2 
 tools/testing/selftests/vm/hmm-tests.c   |  204 ++++++-
 tools/testing/selftests/vm/test_hmm.sh   |   24 
 33 files changed, 1552 insertions(+), 1088 deletions(-)

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

end of thread, other threads:[~2022-02-15  7:25 UTC | newest]

Thread overview: 114+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-10  7:28 start sorting out the ZONE_DEVICE refcount mess v2 Christoph Hellwig
2022-02-10  7:28 ` Christoph Hellwig
2022-02-10  7:28 ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 01/27] mm: remove a pointless CONFIG_ZONE_DEVICE check in memremap_pages Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10 11:37   ` Miaohe Lin
2022-02-10 11:37     ` [Nouveau] " Miaohe Lin
2022-02-10 11:37     ` Miaohe Lin
2022-02-10  7:28 ` [PATCH 02/27] mm: remove the __KERNEL__ guard from <linux/mm.h> Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 03/27] mm: remove pointless includes from <linux/hmm.h> Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  9:39   ` Muchun Song
2022-02-10  9:39     ` [Nouveau] " Muchun Song
2022-02-10  9:39     ` Muchun Song
2022-02-10  7:28 ` [PATCH 04/27] mm: move free_devmap_managed_page to memremap.c Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 05/27] mm: simplify freeing of devmap managed pages Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 06/27] mm: don't include <linux/memremap.h> in <linux/mm.h> Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 07/27] mm: remove the extra ZONE_DEVICE struct page refcount Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 08/27] fsdax: depend on ZONE_DEVICE || FS_DAX_LIMITED Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 09/27] mm: generalize the pgmap based page_free infrastructure Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-14 17:37   ` Logan Gunthorpe
2022-02-14 17:37     ` Logan Gunthorpe
2022-02-14 17:37     ` [Nouveau] " Logan Gunthorpe
2022-02-10  7:28 ` [PATCH 10/27] mm: refactor check_and_migrate_movable_pages Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 11/27] mm: refactor the ZONE_DEVICE handling in migrate_vma_insert_page Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10 10:48   ` Alistair Popple
2022-02-10 10:48     ` Alistair Popple
2022-02-10 10:48     ` [Nouveau] " Alistair Popple
2022-02-10  7:28 ` [PATCH 12/27] mm: refactor the ZONE_DEVICE handling in migrate_vma_pages Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10 10:46   ` Alistair Popple
2022-02-10 10:46     ` Alistair Popple
2022-02-10 10:46     ` [Nouveau] " Alistair Popple
2022-02-10  7:28 ` [PATCH 13/27] mm: move the migrate_vma_* device migration code into it's own file Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10 10:35   ` Alistair Popple
2022-02-10 10:35     ` Alistair Popple
2022-02-10 10:35     ` [Nouveau] " Alistair Popple
2022-02-10 15:23     ` Christoph Hellwig
2022-02-10 15:23       ` Christoph Hellwig
2022-02-10 15:23       ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 14/27] mm: build migrate_vma_* for all configs with ZONE_DEVICE support Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10 10:43   ` Alistair Popple
2022-02-10 10:43     ` Alistair Popple
2022-02-10 10:43     ` [Nouveau] " Alistair Popple
2022-02-10  7:28 ` [PATCH 15/27] mm: add zone device coherent type memory support Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 16/27] mm: add device coherent vma selection for memory migration Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 17/27] mm/gup: fail get_user_pages for LONGTERM dev coherent type Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 18/27] drm/amdkfd: add SPM support for SVM Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 19/27] drm/amdkfd: coherent type as sys mem on migration to ram Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 20/27] lib: test_hmm add ioctl to get zone device type Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 21/27] lib: test_hmm add module param for " Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 22/27] lib: add support for device coherent type in test_hmm Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 23/27] tools: update hmm-test to support device coherent type Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 24/27] tools: update test_hmm script to support SP config Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 25/27] mm: remove the vma check in migrate_vma_setup() Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 26/27] mm/gup: migrate device coherent pages when pinning instead of failing Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10  7:28 ` [PATCH 27/27] tools: add hmm gup test for long term pinned device pages Christoph Hellwig
2022-02-10  7:28   ` Christoph Hellwig
2022-02-10  7:28   ` [Nouveau] " Christoph Hellwig
2022-02-10 10:56 ` start sorting out the ZONE_DEVICE refcount mess v2 Alistair Popple
2022-02-10 10:56   ` Alistair Popple
2022-02-10 10:56   ` [Nouveau] " Alistair Popple
2022-02-10 17:36 ` Sierra Guiza, Alejandro (Alex)
2022-02-10 17:36   ` [Nouveau] " Sierra Guiza, Alejandro (Alex)
2022-02-10 17:36   ` Sierra Guiza, Alejandro (Alex)

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.