Skip to content

fix THP migration for CMA allocations

Rik van Riel linux-mm lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest2 patches 7 repliesIn review 1 of 2 applied
  2. v12 patches 9 repliesSuperseded

Changes in v2 from the cover letter

- addressed comments by Vlastimil Babka and Zi Yan

Patches in v2 1 of 2 applied

#Subject and filesSizeRepliesApplied
1/2mm,compaction,cma: add alloc_contig flag to compact_controlmm/internal.h mm/page_alloc.c+2 -00 repliesApplied
2/2mm,thp,compaction,cma: allow THP migration for CMA allocationsmm/compaction.c mm/page_alloc.c+20 -118 replies

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by.

PatchZi YanVlastimil Babka
1/2R-b
2/2R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/2] fix THP migration for CMA allocations

Transparent huge pages are allocated with __GFP_MOVABLE, and can end up in CMA memory blocks. Transparent huge pages also have most of the infrastructure in place to allow migration.

However, a few pieces were missing, causing THP migration to fail when attempting to use CMA to allocate 1GB hugepages.

With these patches in place, THP migration from CMA blocks seems to work, both for anonymous THPs and for tmpfs/shmem THPs.

v2:
- addressed comments by Vlastimil Babka and Zi Yan

Rik van Riel (2):
mm,compaction,cma: add alloc_contig flag to compact_control mm,thp,compaction,cma: allow THP migration for CMA allocations

 mm/compaction.c | 16 +++++++++-------
 mm/internal.h   |  1 +
 mm/page_alloc.c |  7 +++++--
 3 files changed, 15 insertions(+), 9 deletions(-)
Signature · 1 line
2.24.1