lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 30 Mar 2015 12:59:01 +0100
From:	Mel Gorman <mgorman@...e.de>
To:	Naoya Horiguchi <nao.horiguchi@...il.com>
Cc:	Naoya Horiguchi <n-horiguchi@...jp.nec.com>,
	"linux-mm@...ck.org" <linux-mm@...ck.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Hugh Dickins <hughd@...gle.com>,
	"Kirill A. Shutemov" <kirill@...temov.name>,
	David Rientjes <rientjes@...gle.com>,
	Rik van Riel <riel@...hat.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [RFC][PATCH] mm: hugetlb: add stub-like do_hugetlb_numa()

On Mon, Mar 30, 2015 at 07:42:13PM +0900, Naoya Horiguchi wrote:
> On 03/30/2015 07:28 PM, Mel Gorman wrote:
> >On Mon, Mar 30, 2015 at 09:40:54AM +0000, Naoya Horiguchi wrote:
> >>hugetlb doesn't support NUMA balancing now, but that doesn't mean that we
> >>don't have to make hugetlb code prepared for PROTNONE entry properly.
> >>In the current kernel, when a process accesses to hugetlb range protected
> >>with PROTNONE, it causes unexpected COWs, which finally put hugetlb subsystem
> >>into broken/uncontrollable state, where for example h->resv_huge_pages is
> >>subtracted too much and wrapped around to a very large number, and free
> >>hugepage pool is no longer maintainable.
> >>
> >
> >Ouch!
> >
> >>This patch simply clears PROTNONE when it's caught out. Real NUMA balancing
> >>code for hugetlb is not implemented yet (not sure how much it's worth doing.)
> >>
> >
> >It's not worth doing at all. Furthermore, an application that took the
> >effort to allocate and use hugetlb pages is not going to appreciate the
> >minor faults incurred by automatic balancing for no gain.
> 
> OK,
> 
> >Why not something
> >like the following untested patch?
> 
> I'll test this tomorrow.
> Thank you very much for the comment.
> 

I note now that the patch was too hasty. By rights, that check
should be covered by vma_migratable() but it's only checked if
CONFIG_ARCH_ENABLE_HUGEPAGE_MIGRATION which means it's x86-only. If you
are seeing this problem on any other arch then a more correct fix might be
to remove the CONFIG_ARCH_ENABLE_HUGEPAGE_MIGRATION check in vma_migratable.

-- 
Mel Gorman
SUSE Labs
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ