Message ID | 20201029193405.29125-17-willy@infradead.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Transparent Hugepages for non-tmpfs filesystems | expand |
diff --git a/mm/huge_memory.c b/mm/huge_memory.c index 580afce93d4a..660fe8c29cd9 100644 --- a/mm/huge_memory.c +++ b/mm/huge_memory.c @@ -556,13 +556,10 @@ unsigned long thp_get_unmapped_area(struct file *filp, unsigned long addr, unsigned long ret; loff_t off = (loff_t)pgoff << PAGE_SHIFT; - if (!IS_DAX(filp->f_mapping->host) || !IS_ENABLED(CONFIG_FS_DAX_PMD)) - goto out; - ret = __thp_get_unmapped_area(filp, addr, len, off, flags, PMD_SIZE); if (ret) return ret; -out: + return current->mm->get_unmapped_area(filp, addr, len, pgoff, flags); } EXPORT_SYMBOL_GPL(thp_get_unmapped_area);