convert core hugetlb functions to folios
Status from this message: [merged mm-stable] mm-hugetlb-change-hugetlb-allocation-functions-to-return-a-folio.patch removed from -mm tree
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v5 Latest10 patches 22 repliesApplied 10/10
- v410 patches 4 repliesSuperseded
- v310 patches 2 repliesSuperseded
Earlier versions · 2
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v2 | 10 patches | 0 replies | Superseded | |
| v1 | 10 patches | 0 replies | Superseded |
Changes in v5 from the cover letter
- change comment with HPageVmemmapOptimized to hugetlb_vmemmap_optimized per Tarun Sahu
- fix Smatch warning in patch 10 by reorganizing alloc_pool_huge_page
- fix NULL pointer dereference issue in patch 10 per John Hubbard
- use NULL rather than 0 in patch 6 per David Hildenbrand
Patches in v5 All 10 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/10 | mm: add folio dtor and order setter functionsinclude/ mm/ | +17 | 13 replies | Applied |
| 2/10 | mm/hugetlb: convert destroy_compound_gigantic_page() to foliosmm/ | +21 | 1 reply | Applied |
| 3/10 | mm/hugetlb: convert dissolve_free_huge_page() to foliosmm/ | +10 | 1 reply | Applied |
| 4/10 | mm/hugetlb: convert remove_hugetlb_page() to foliosmm/ | +25 | 1 reply | Applied |
| 5/10 | mm/hugetlb: convert update_and_free_page() to foliosmm/ | +16 | 1 reply | Applied |
| 6/10 | mm/hugetlb: convert add_hugetlb_page() to folios and add hugetlb_cma_folio()mm/ | +21 | 1 reply | Applied |
| 7/10 | mm/hugetlb: convert enqueue_huge_page() to foliosmm/ | +11 | 1 reply | Applied |
| 8/10 | mm/hugetlb: convert free_gigantic_page() to foliosmm/ | +17 | 1 reply | Applied |
| 9/10 | mm/hugetlb: convert hugetlb prep functions to foliosmm/ | +30 | 1 reply | Applied |
| 10/10 | mm/hugetlb: change hugetlb allocation functions to return a foliomm/ | +57 | 1 reply | Applied |
Reviews trailers per patch
All 10 patches have a Reviewed-by or Acked-by.
| Patch | Mike Kravetz |
|---|---|
| 1/10 | R-b |
| 2/10 | R-b |
| 3/10 | R-b |
| 4/10 | R-b |
| 5/10 | R-b |
| 6/10 | R-b |
| 7/10 | R-b |
| 8/10 | R-b |
| 9/10 | R-b |
| 10/10 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH mm-unstable v5 00/10] convert core hugetlb functions to folios
============== OVERVIEW ===========================
Now that many hugetlb helper functions that deal with hugetlb specific flags[1] and hugetlb cgroups[2] are converted to folios, higher level allocation, prep, and freeing functions within hugetlb can also be converted to operate in folios.
Patch 1 of this series implements the wrapper functions around setting the compound destructor and compound order for a folio. Besides the user added in patch 1, patch 2 and patch 9 also use these helper functions.
Patches 2-10 convert the higher level hugetlb functions to folios.
============== TESTING ===========================
LTP:
Ran 10 back to back rounds of the LTP hugetlb test suite.
Gigantic Huge Pages:
Test allocation and freeing via hugeadm commands: hugeadm --pool-pages-min 1GB:10 hugeadm --pool-pages-min 1GB:0
Demote:
Demote 1 1GB hugepages to 512 2MB hugepages echo 1 > /sys/kernel/mm/hugepages/hugepages-1048576kB/nr_hugepages echo 1 > /sys/kernel/mm/hugepages/hugepages-1048576kB/demote cat /sys/kernel/mm/hugepages/hugepages-2048kB/nr_hugepages # 512 cat /sys/kernel/mm/hugepages/hugepages-1048576kB/nr_hugepages # 0
Rebased on 10/29/2022 mm-unstable
[1] https://lore.kernel.org/lkml/[email protected]/
[2] https://lore.kernel.org/linux-mm/[email protected]/
v1 -> v2:
- fix conflict with "mm,thp,rmap: simplify compound page mapcount handling"
v2 -> v3:
- v2 contained wrong version of patch 1
v3 -> v4:
- change instances of folio_{clear, set}_head() to __folio_{clear, set}_head()
- rebase on top of hugetlb: Fix __prep_compound_gigantic_page page flag setting
v4 -> v5:
- change comment with HPageVmemmapOptimized to hugetlb_vmemmap_optimized per Tarun Sahu
- fix Smatch warning in patch 10 by reorganizing alloc_pool_huge_page
- fix NULL pointer dereference issue in patch 10 per John Hubbard
- use NULL rather than 0 in patch 6 per David Hildenbrand
Sidhartha Kumar (10):
mm: add folio dtor and order setter functions mm/hugetlb: convert destroy_compound_gigantic_page() to folios mm/hugetlb: convert dissolve_free_huge_page() to folios mm/hugetlb: convert remove_hugetlb_page() to folios mm/hugetlb: convert update_and_free_page() to folios mm/hugetlb: convert add_hugetlb_page() to folios and add
hugetlb_cma_folio()
mm/hugetlb: convert enqueue_huge_page() to folios mm/hugetlb: convert free_gigantic_page() to folios mm/hugetlb: convert hugetlb prep functions to folios mm/hugetlb: change hugetlb allocation functions to return a folio
include/linux/mm.h | 16 ++ mm/hugetlb.c | 409 ++++++++++++++++++++++----------------------- 2 files changed, 219 insertions(+), 206 deletions(-)
Signature · 1 line
2.38.1