mm: use the correct page size when removing the page
Subsystems (2)
[email protected]
maintainerPATCH 39/123 mm: use the correct page size when removing the page
From: "Aneesh Kumar K.V" <[email protected]>
Subject: mm: use the correct page size when removing the page
We are removing a pmd hugepage here. Use the correct page size.
Signed-off-by Aneesh Kumar K.V <[email protected]>
Cc "Kirill A. Shutemov" <[email protected]>
Cc Dan Williams <[email protected]>
Cc Ross Zwisler <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
mm/huge_memory.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
mm/huge_memory.c renamed from mm/huge_memory.c~mm-use-the-correct-page-size-when-removing-the-page +2 -2
@@ -1399,12 +1399,12 @@ int zap_huge_pmd(struct mmu_gather *tlb,if (vma_is_dax (vma)) {spin_unlock (ptl);if (is_huge_zero_pmd (orig_pmd)) -tlb_remove_page (tlb,pmd_page (orig_pmd)); +tlb_remove_page_size (tlb,pmd_page (orig_pmd),HPAGE_PMD_SIZE ); }else if (is_huge_zero_pmd (orig_pmd)) {pte_free (tlb->mm,pgtable_trans_huge_withdraw (tlb->mm, pmd));atomic_long_dec (&tlb->mm->nr_ptes);spin_unlock (ptl); -tlb_remove_page (tlb,pmd_page (orig_pmd)); +tlb_remove_page_size (tlb,pmd_page (orig_pmd),HPAGE_PMD_SIZE ); }else {struct page *page =pmd_page (orig_pmd);page_remove_rmap (page, true);
_