Re: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Naoya Horiguchi
On Tue, Feb 17, 2015 at 04:02:49PM -0800, Andrew Morton wrote: > On Tue, 17 Feb 2015 15:57:44 -0800 Andrew Morton > wrote: > > > So if I'm understanding this correctly, hugepages never have PG_lru set > > and so you are overloading that bit on hugepages to indicate that the > > page is present

Re: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Naoya Horiguchi
On Tue, Feb 17, 2015 at 03:57:44PM -0800, Andrew Morton wrote: > On Tue, 17 Feb 2015 09:32:08 + Naoya Horiguchi > wrote: > > > Currently we are not safe from concurrent calls of isolate_huge_page(), > > which can make the victim hugepage in invalid state and results in BUG_ON(). > > > >

Re: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Andrew Morton
On Tue, 17 Feb 2015 15:57:44 -0800 Andrew Morton wrote: > So if I'm understanding this correctly, hugepages never have PG_lru set > and so you are overloading that bit on hugepages to indicate that the > page is present on hstate->hugepage_activelist? And maybe we don't need to overload PG_lru

Re: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Andrew Morton
On Tue, 17 Feb 2015 09:32:08 + Naoya Horiguchi wrote: > Currently we are not safe from concurrent calls of isolate_huge_page(), > which can make the victim hugepage in invalid state and results in BUG_ON(). > > The root problem of this is that we don't have any information on struct page >

[PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Naoya Horiguchi
t; hugepage") > Signed-off-by: Naoya Horiguchi > Cc: [3.12+] Sorry, my testing was not enough and I found a bug in soft offline code. Here is the updated one. Thanks, Naoya Horiguchi From e69950011360f624e08712de4d541c7d686d6296 Mon Sep 17 00:00:00 2001 From: Naoya Ho

Re: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Naoya Horiguchi
On Tue, Feb 17, 2015 at 04:02:49PM -0800, Andrew Morton wrote: On Tue, 17 Feb 2015 15:57:44 -0800 Andrew Morton a...@linux-foundation.org wrote: So if I'm understanding this correctly, hugepages never have PG_lru set and so you are overloading that bit on hugepages to indicate that the

Re: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Andrew Morton
On Tue, 17 Feb 2015 09:32:08 + Naoya Horiguchi n-horigu...@ah.jp.nec.com wrote: Currently we are not safe from concurrent calls of isolate_huge_page(), which can make the victim hugepage in invalid state and results in BUG_ON(). The root problem of this is that we don't have any

Re: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Naoya Horiguchi
On Tue, Feb 17, 2015 at 03:57:44PM -0800, Andrew Morton wrote: On Tue, 17 Feb 2015 09:32:08 + Naoya Horiguchi n-horigu...@ah.jp.nec.com wrote: Currently we are not safe from concurrent calls of isolate_huge_page(), which can make the victim hugepage in invalid state and results in

Re: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Andrew Morton
On Tue, 17 Feb 2015 15:57:44 -0800 Andrew Morton a...@linux-foundation.org wrote: So if I'm understanding this correctly, hugepages never have PG_lru set and so you are overloading that bit on hugepages to indicate that the page is present on hstate-hugepage_activelist? And maybe we don't

[PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages

2015-02-17 Thread Naoya Horiguchi
Subject: [PATCH v2] mm, hugetlb: set PageLRU for in-use/active hugepages Currently we are not safe from concurrent calls of isolate_huge_page(), which can make the victim hugepage in invalid state and results in BUG_ON(). The root problem of this is that we don't have any information on struct page (so