diff --git a/mm/hugetlb.c b/mm/hugetlb.c index f4c43d7980b..b21d78c941b 100644 --- a/mm/hugetlb.c +++ b/mm/hugetlb.c @@ -12,6 +12,7 @@ #include #include #include +#include #include #include @@ -48,7 +49,8 @@ static struct page *dequeue_huge_page(struct vm_area_struct *vma, for (z = zonelist->zones; *z; z++) { nid = (*z)->zone_pgdat->node_id; - if (!list_empty(&hugepage_freelists[nid])) + if (cpuset_zone_allowed(*z, GFP_HIGHUSER) && + !list_empty(&hugepage_freelists[nid])) break; }