Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3652586pxk; Tue, 29 Sep 2020 02:41:50 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxtnz4w54FpaKjvtWQYSNngSSFXiL7qYJynxPvy6EFAHwHh2mfogW03M7jfFGg8YHfY5nA9 X-Received: by 2002:a50:fd0a:: with SMTP id i10mr2207656eds.277.1601372509979; Tue, 29 Sep 2020 02:41:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601372509; cv=none; d=google.com; s=arc-20160816; b=HEKIfaOmb0V5zH+JMEOAVUIl3a+WMjcpwQVjUGV3W0y7ejfjcyZy/YBW52LnWQIfZa 0GCkItao88kiG3zWJQYDzHoe0OJdJsPZuaHNshhlaRTX0AxUoi8y9Z567/R+fq1hLxMb a7EfavE2fDafEoDmsv8AaX24mV4S9W+1MRLr1lC9fhU7NN8bye172jocr5bdX4h8JaZP NkXTXNVsVYam0Ga+5njZ1LfcOfdSnzqx6KT/3XhGvn/aI00VwdUqL+QMyVbGbraH+OEl pDvI1EzJiyu720+eaGwW1NSH4ho3JHdSm5GO/I329+snguWS+l5zxGb8NomT2zjev4uw R0Gw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:reply-to:message-id:subject:cc:to:from:date; bh=cOlxyKcqh0PXSWRCfh54kUNBR2scq5lgh7eWEvZ7wWk=; b=b6+tNoUrs+wjYt/9Aqd91NCWEv6NzM1GUU5rSnRheMKsvt05z8CrQIA567iLjGKqng lonabBRVs5nYJeuB8BgmkNYL8T14GYegMW74mKQO2JQvHzGL2mah/PNgzMZSfrAmDwpM pbNL6Wunkm1pwSib6iZhP0vQynNp27Lf2mwn6a3rZUooUpi10q5UKVdAouEKKYP5iBbL bJ0hwpU/9nvRyHB6EyshnkNeWbLnzzaRLgRLfbE/nk//URGT/5CuPKMajadj686wZjKu 49qn1xv8uuenja+S91HHpXpZ9gStW8Dx+1ZjxEWVG3CrNQVFkkmRDvy7KzRaoMEgbv2G 2RBQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w23si2281085eju.558.2020.09.29.02.41.26; Tue, 29 Sep 2020 02:41:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727817AbgI2Jk1 (ORCPT + 99 others); Tue, 29 Sep 2020 05:40:27 -0400 Received: from out30-56.freemail.mail.aliyun.com ([115.124.30.56]:50140 "EHLO out30-56.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727698AbgI2Jk0 (ORCPT ); Tue, 29 Sep 2020 05:40:26 -0400 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R181e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04426;MF=richard.weiyang@linux.alibaba.com;NM=1;PH=DS;RN=15;SR=0;TI=SMTPD_---0UATyNsI_1601372421; Received: from localhost(mailfrom:richard.weiyang@linux.alibaba.com fp:SMTPD_---0UATyNsI_1601372421) by smtp.aliyun-inc.com(127.0.0.1); Tue, 29 Sep 2020 17:40:21 +0800 Date: Tue, 29 Sep 2020 17:40:21 +0800 From: Wei Yang To: David Hildenbrand Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-hyperv@vger.kernel.org, xen-devel@lists.xenproject.org, linux-acpi@vger.kernel.org, Andrew Morton , Alexander Duyck , Mel Gorman , Michal Hocko , Dave Hansen , Vlastimil Babka , Wei Yang , Oscar Salvador , Mike Rapoport Subject: Re: [PATCH v1 5/5] mm/memory_hotplug: update comment regarding zone shuffling Message-ID: <20200929094021.GD36904@L-31X9LVDL-1304.local> Reply-To: Wei Yang References: <20200928182110.7050-1-david@redhat.com> <20200928182110.7050-6-david@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200928182110.7050-6-david@redhat.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Sep 28, 2020 at 08:21:10PM +0200, David Hildenbrand wrote: >As we no longer shuffle via generic_online_page() and when undoing >isolation, we can simplify the comment. > >We now effectively shuffle only once (properly) when onlining new >memory. > >Cc: Andrew Morton >Cc: Alexander Duyck >Cc: Mel Gorman >Cc: Michal Hocko >Cc: Dave Hansen >Cc: Vlastimil Babka >Cc: Wei Yang >Cc: Oscar Salvador >Cc: Mike Rapoport >Signed-off-by: David Hildenbrand Reviewed-by: Wei Yang >--- > mm/memory_hotplug.c | 11 ++++------- > 1 file changed, 4 insertions(+), 7 deletions(-) > >diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c >index 9db80ee29caa..c589bd8801bb 100644 >--- a/mm/memory_hotplug.c >+++ b/mm/memory_hotplug.c >@@ -859,13 +859,10 @@ int __ref online_pages(unsigned long pfn, unsigned long nr_pages, > undo_isolate_page_range(pfn, pfn + nr_pages, MIGRATE_MOVABLE); > > /* >- * When exposing larger, physically contiguous memory areas to the >- * buddy, shuffling in the buddy (when freeing onlined pages, putting >- * them either to the head or the tail of the freelist) is only helpful >- * for maintaining the shuffle, but not for creating the initial >- * shuffle. Shuffle the whole zone to make sure the just onlined pages >- * are properly distributed across the whole freelist. Make sure to >- * shuffle once pageblocks are no longer isolated. >+ * Freshly onlined pages aren't shuffled (e.g., all pages are placed to >+ * the tail of the freelist when undoing isolation). Shuffle the whole >+ * zone to make sure the just onlined pages are properly distributed >+ * across the whole freelist - to create an initial shuffle. > */ > shuffle_zone(zone); > >-- >2.26.2 -- Wei Yang Help you, Help me