Re: [patch v2 -mm] mm, hugetlb: schedule when potentially allocating many hugepages

From: Anshuman Khandual
Date: Thu Jul 06 2017 - 02:08:50 EST


On 06/10/2017 04:06 AM, David Rientjes wrote:
> A few hugetlb allocators loop while calling the page allocator and can
> potentially prevent rescheduling if the page allocator slowpath is not
> utilized.
>
> Conditionally schedule when large numbers of hugepages can be allocated.
>
> Signed-off-by: David Rientjes <rientjes@xxxxxxxxxx>

Fixes a task which was getting hung while writing like 10000
hugepages (16MB on POWER8) into /proc/sys/vm/nr_hugepages.

Tested-by: Anshuman Khandual <khandual@xxxxxxxxxxxxxxxxxx>