The patch titled hugetlb: use free_pool_huge_page() to return unused surplus pages fix has been removed from the -mm tree. Its filename was hugetlb-use-free_pool_huge_page-to-return-unused-surplus-pages-fix.patch This patch was dropped because it was folded into hugetlb-use-free_pool_huge_page-to-return-unused-surplus-pages.patch The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: hugetlb: use free_pool_huge_page() to return unused surplus pages fix From: Lee Schermerhorn <Lee.Schermerhorn@xxxxxx> Fixes bug detected by libhugetlbfs test suite in: hugetlb-use-free_pool_huge_page-to-return-unused-surplus-pages.patch Can't just "continue" for node with no surplus pages when returning unused surplus. We need to advance to 'next node to free'. With this fix, the "hugetlb balance free across nodes" series passes the test suite. Signed-off-by: Lee Schermerhorn <lee.schermerhorn@xxxxxx> Cc: Mel Gorman <mel@xxxxxxxxx> Cc: Nishanth Aravamudan <nacc@xxxxxxxxxx> Cc: David Rientjes <rientjes@xxxxxxxxxx> Cc: Adam Litke <agl@xxxxxxxxxx> Cc: Andy Whitcroft <apw@xxxxxxxxxxxxx> Cc: Eric Whitney <eric.whitney@xxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/hugetlb.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff -puN mm/hugetlb.c~hugetlb-use-free_pool_huge_page-to-return-unused-surplus-pages-fix mm/hugetlb.c --- a/mm/hugetlb.c~hugetlb-use-free_pool_huge_page-to-return-unused-surplus-pages-fix +++ a/mm/hugetlb.c @@ -698,13 +698,11 @@ static int free_pool_huge_page(struct hs do { /* - * If we're returning unused surplus pages, skip nodes - * with no surplus. + * If we're returning unused surplus pages, only examine + * nodes with surplus pages. */ - if (acct_surplus && !h->surplus_huge_pages_node[next_nid]) - continue; - - if (!list_empty(&h->hugepage_freelists[next_nid])) { + if ((!acct_surplus || h->surplus_huge_pages_node[next_nid]) && + !list_empty(&h->hugepage_freelists[next_nid])) { struct page *page = list_entry(h->hugepage_freelists[next_nid].next, struct page, lru); _ Patches currently in -mm which might be from Lee.Schermerhorn@xxxxxx are hugetlb-restore-interleaving-of-bootmem-huge-pages-2631.patch hugetlb-use-free_pool_huge_page-to-return-unused-surplus-pages.patch hugetlb-use-free_pool_huge_page-to-return-unused-surplus-pages-fix.patch hugetlb-restore-interleaving-of-bootmem-huge-pages.patch mmap-avoid-unnecessary-anon_vma-lock-acquisition-in-vma_adjust.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html