Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Kirill A. Shutemov
On Fri, Oct 26, 2012 at 04:07:44PM +0200, Peter Zijlstra wrote: > On Fri, 2012-10-26 at 16:57 +0300, Kirill A. Shutemov wrote: > > > > Yes, this code will catch it: > > > > > > > > /* if an huge pmd materialized from under us just retry later */ > > > > if (unlikely(pmd_trans_huge(*pmd)))

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Peter Zijlstra
On Fri, 2012-10-26 at 16:57 +0300, Kirill A. Shutemov wrote: > > > Yes, this code will catch it: > > > > > > /* if an huge pmd materialized from under us just retry later */ > > > if (unlikely(pmd_trans_huge(*pmd))) > > > return 0; > > > > > > If the pmd is under splitting

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Kirill A. Shutemov
On Fri, Oct 26, 2012 at 03:43:12PM +0200, Peter Zijlstra wrote: > On Fri, 2012-10-26 at 16:41 +0300, Kirill A. Shutemov wrote: > > On Fri, Oct 26, 2012 at 03:08:05PM +0200, Peter Zijlstra wrote: > > > On Fri, 2012-10-26 at 15:54 +0300, Kirill A. Shutemov wrote: > > > > From: "Kirill A. Shutemov"

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Peter Zijlstra
On Fri, 2012-10-26 at 16:41 +0300, Kirill A. Shutemov wrote: > On Fri, Oct 26, 2012 at 03:08:05PM +0200, Peter Zijlstra wrote: > > On Fri, 2012-10-26 at 15:54 +0300, Kirill A. Shutemov wrote: > > > From: "Kirill A. Shutemov" > > > > > > We check if the pmd entry is the same as on

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Kirill A. Shutemov
On Fri, Oct 26, 2012 at 03:08:05PM +0200, Peter Zijlstra wrote: > On Fri, 2012-10-26 at 15:54 +0300, Kirill A. Shutemov wrote: > > From: "Kirill A. Shutemov" > > > > We check if the pmd entry is the same as on pmd_trans_huge() in > > handle_mm_fault(). That's enough. > > > > Signed-off-by:

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Peter Zijlstra
On Fri, 2012-10-26 at 15:54 +0300, Kirill A. Shutemov wrote: > From: "Kirill A. Shutemov" > > We check if the pmd entry is the same as on pmd_trans_huge() in > handle_mm_fault(). That's enough. > > Signed-off-by: Kirill A. Shutemov Ah indeed, Will mentioned something like this on IRC as well,

[PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Kirill A. Shutemov
From: "Kirill A. Shutemov" We check if the pmd entry is the same as on pmd_trans_huge() in handle_mm_fault(). That's enough. Signed-off-by: Kirill A. Shutemov --- mm/huge_memory.c |6 -- 1 file changed, 6 deletions(-) diff --git a/mm/huge_memory.c b/mm/huge_memory.c index

[PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Kirill A. Shutemov
From: Kirill A. Shutemov kirill.shute...@linux.intel.com We check if the pmd entry is the same as on pmd_trans_huge() in handle_mm_fault(). That's enough. Signed-off-by: Kirill A. Shutemov kirill.shute...@linux.intel.com --- mm/huge_memory.c |6 -- 1 file changed, 6 deletions(-) diff

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Peter Zijlstra
On Fri, 2012-10-26 at 15:54 +0300, Kirill A. Shutemov wrote: From: Kirill A. Shutemov kirill.shute...@linux.intel.com We check if the pmd entry is the same as on pmd_trans_huge() in handle_mm_fault(). That's enough. Signed-off-by: Kirill A. Shutemov kirill.shute...@linux.intel.com Ah

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Kirill A. Shutemov
On Fri, Oct 26, 2012 at 03:08:05PM +0200, Peter Zijlstra wrote: On Fri, 2012-10-26 at 15:54 +0300, Kirill A. Shutemov wrote: From: Kirill A. Shutemov kirill.shute...@linux.intel.com We check if the pmd entry is the same as on pmd_trans_huge() in handle_mm_fault(). That's enough.

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Peter Zijlstra
On Fri, 2012-10-26 at 16:41 +0300, Kirill A. Shutemov wrote: On Fri, Oct 26, 2012 at 03:08:05PM +0200, Peter Zijlstra wrote: On Fri, 2012-10-26 at 15:54 +0300, Kirill A. Shutemov wrote: From: Kirill A. Shutemov kirill.shute...@linux.intel.com We check if the pmd entry is the same as

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Kirill A. Shutemov
On Fri, Oct 26, 2012 at 03:43:12PM +0200, Peter Zijlstra wrote: On Fri, 2012-10-26 at 16:41 +0300, Kirill A. Shutemov wrote: On Fri, Oct 26, 2012 at 03:08:05PM +0200, Peter Zijlstra wrote: On Fri, 2012-10-26 at 15:54 +0300, Kirill A. Shutemov wrote: From: Kirill A. Shutemov

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Peter Zijlstra
On Fri, 2012-10-26 at 16:57 +0300, Kirill A. Shutemov wrote: Yes, this code will catch it: /* if an huge pmd materialized from under us just retry later */ if (unlikely(pmd_trans_huge(*pmd))) return 0; If the pmd is under splitting it's still a

Re: [PATCH 1/2] numa, mm: drop redundant check in do_huge_pmd_numa_page()

2012-10-26 Thread Kirill A. Shutemov
On Fri, Oct 26, 2012 at 04:07:44PM +0200, Peter Zijlstra wrote: On Fri, 2012-10-26 at 16:57 +0300, Kirill A. Shutemov wrote: Yes, this code will catch it: /* if an huge pmd materialized from under us just retry later */ if (unlikely(pmd_trans_huge(*pmd)))