diff options
-rw-r--r-- | mm/migrate.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/mm/migrate.c b/mm/migrate.c index 8d084e9bc13b..46cca5c2ebff 100644 --- a/mm/migrate.c +++ b/mm/migrate.c @@ -1554,6 +1554,11 @@ struct page *new_page_nodemask(struct page *page, } if (PageTransHuge(page)) { + /* + * clear __GFP_RECLAIM to make the migration callback + * consistent with regular THP allocations. + */ + gfp_mask &= ~__GFP_RECLAIM; gfp_mask |= GFP_TRANSHUGE; order = HPAGE_PMD_ORDER; } |