From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756723Ab0JSXas (ORCPT ); Tue, 19 Oct 2010 19:30:48 -0400 Received: from smtp1.linux-foundation.org ([140.211.169.13]:48977 "EHLO smtp1.linux-foundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751178Ab0JSXar (ORCPT ); Tue, 19 Oct 2010 19:30:47 -0400 Date: Tue, 19 Oct 2010 16:29:40 -0700 From: Andrew Morton To: David Rientjes Cc: KOSAKI Motohiro , KAMEZAWA Hiroyuki , Mel Gorman , LKML , linux-mm , Christoph Lameter Subject: Re: [resend][PATCH 2/2] mm, mem-hotplug: update pcp->stat_threshold when memory hotplug occur Message-Id: <20101019162940.6918506d.akpm@linux-foundation.org> In-Reply-To: References: <20101019140831.A1EB.A69D9226@jp.fujitsu.com> <20101019140955.A1EE.A69D9226@jp.fujitsu.com> X-Mailer: Sylpheed 2.4.8 (GTK+ 2.12.9; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 19 Oct 2010 12:11:09 -0700 (PDT) David Rientjes wrote: > On Tue, 19 Oct 2010, KOSAKI Motohiro wrote: > > > diff --git a/mm/page_alloc.c b/mm/page_alloc.c > > index 14ee899..222d8cc 100644 > > --- a/mm/page_alloc.c > > +++ b/mm/page_alloc.c > > @@ -51,6 +51,7 @@ > > #include > > #include > > #include > > +#include > > #include > > #include > > > > @@ -5013,6 +5014,8 @@ int __meminit init_per_zone_wmark_min(void) > > min_free_kbytes = 128; > > if (min_free_kbytes > 65536) > > min_free_kbytes = 65536; > > + > > + refresh_zone_stat_thresholds(); > > setup_per_zone_wmarks(); > > setup_per_zone_lowmem_reserve(); > > setup_per_zone_inactive_ratio(); > > setup_per_zone_wmarks() could change the min and low watermarks for a zone > when refresh_zone_stat_thresholds() would have used the old value. Indeed. I could make the obvious fix, but then what I'd have wouldn't be sufficiently tested.