From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754494AbcGVULd (ORCPT ); Fri, 22 Jul 2016 16:11:33 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:54890 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752841AbcGVULF (ORCPT ); Fri, 22 Jul 2016 16:11:05 -0400 Date: Fri, 22 Jul 2016 13:11:03 -0700 From: Andrew Morton To: Xishi Qiu Cc: Joonsoo Kim , Vlastimil Babka , Naoya Horiguchi , David Rientjes , Linux MM , LKML Subject: Re: [PATCH v2] mem-hotplug: alloc new page from the next node if zone is MOVABLE_ZONE Message-Id: <20160722131103.23c02a66d086df8f2ddae601@linux-foundation.org> In-Reply-To: <57918BAC.8000008@huawei.com> References: <57918BAC.8000008@huawei.com> X-Mailer: Sylpheed 3.4.1 (GTK+ 2.24.23; 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 Fri, 22 Jul 2016 10:57:48 +0800 Xishi Qiu wrote: > Memory offline could happen on both movable zone and non-movable zone. > We can offline the whole node if the zone is movable zone, and if the > zone is non-movable zone, we cannot offline the whole node, because > some kernel memory can't be migrated. > > So if we offline a node with movable zone, use prefer mempolicy to alloc > new page from the next node instead of the current node or other remote > nodes, because re-migrate is a waste of time and the distance of the > remote nodes is often very large. > > Also use GFP_HIGHUSER_MOVABLE to alloc new page if the zone is movable > zone. This conflicts pretty significantly with your "mem-hotplug: use different mempolicy in alloc_migrate_target()". Does it replace "mem-hotplug: use different mempolicy in alloc_migrate_target()" and your "mem-hotplug: use GFP_HIGHUSER_MOVABLE in, alloc_migrate_target()", or what?