lkml.org 
[lkml]   [2020]   [Sep]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[RFC PATCH v2 30/30] mm: thp: enable anonymous PUD THP at page fault path.
Date
From: Zi Yan <ziy@nvidia.com>

All previous commits have anonymous PUD THP support ready, so we can
enable anonymous PUD THP page fault now.

Signed-off-by: Zi Yan <ziy@nvidia.com>
---
mm/memory.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/mm/memory.c b/mm/memory.c
index 9f7b509a3aa7..dc285d9872fc 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -4122,16 +4122,15 @@ static vm_fault_t create_huge_pud(struct vm_fault *vmf)
{
#if defined(CONFIG_TRANSPARENT_HUGEPAGE) && \
defined(CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE_PUD)
- /* No support for anonymous transparent PUD pages yet */
if (vma_is_anonymous(vmf->vma))
- goto split;
+ return do_huge_pud_anonymous_page(vmf);
if (vmf->vma->vm_ops->huge_fault) {
vm_fault_t ret = vmf->vma->vm_ops->huge_fault(vmf, PE_SIZE_PUD);

if (!(ret & VM_FAULT_FALLBACK))
return ret;
}
-split:
+
/* COW or write-notify not handled on PUD level: split pud.*/
__split_huge_pud(vmf->vma, vmf->pud, vmf->address, false, NULL);
#endif /* CONFIG_TRANSPARENT_HUGEPAGE */
--
2.28.0
\
 
 \ /
  Last update: 2020-09-28 20:02    [W:0.130 / U:9.424 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site