From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6C5A519E7ED for ; Wed, 15 Jan 2025 23:42:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736984564; cv=none; b=njnaYpoZWmMDkit7+QN+S2rS1gJ2mslWar0nj4IevRdGN2+vMLJIT0bsX+fP8ERARNHXs/xDFvw/n+OJZJr6koJuPBwKnbrKU//KoRkzz07NvUXff3kWF9qirI33Cy1viwVWsjRipr/jDaFuG2LnZOYrLB7usKx9v45mrjJ8nuM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736984564; c=relaxed/simple; bh=VnvU1gCjg7e+HADAX4HJ3WOyvblpry0hZ6+1mhIxsbE=; h=Date:From:To:Cc:Subject:Message-Id:In-Reply-To:References: Mime-Version:Content-Type; b=QQVyTMvCQI4MoZWaq10+uxopY+Oq70amUNIVpoSeMEow+rGRgh6Wi+GVsGVpswRS+7ZxFAgZ3SUJBB37+dkqJFQJNNGRssWB85lChvmpPKCSGrfy+4XEuxUMbDQH1RD5AB67rwE2NJ+88oOSENWGmGSmVq27aSvzN3NL4QaFktk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b=oYGnh4AT; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="oYGnh4AT" Received: by smtp.kernel.org (Postfix) with ESMTPSA id CA95CC4CED1; Wed, 15 Jan 2025 23:42:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1736984564; bh=VnvU1gCjg7e+HADAX4HJ3WOyvblpry0hZ6+1mhIxsbE=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=oYGnh4ATN+hfZHYhpzioYH3mG6rhP2qNcxVvtio3P2HRFtfdKXYIg6j6CrSy4ItTq Rcxf5NV3sqUD7EczsTyU37ixCyH0cvzyO/+ht8mqTNz5pIBdl95pEIEwsHrQeTRXBP Kr/KiBWZm4NX6o4wCOt71ZIcRH6KMBiExDfIVFy4= Date: Wed, 15 Jan 2025 15:42:43 -0800 From: Andrew Morton To: Yuntao Wang Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, Michal Hocko Subject: Re: [PATCH] mm/page_alloc: Remove the incorrect and misleading comment Message-Id: <20250115154243.4a31f9fbf805169d2c5594dd@linux-foundation.org> In-Reply-To: <20250115041634.63387-1-yuntao.wang@linux.dev> References: <20250115041634.63387-1-yuntao.wang@linux.dev> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Wed, 15 Jan 2025 12:16:34 +0800 Yuntao Wang wrote: > The comment removed in this patch originally belonged to the > build_zonelists_in_zone_order() function, which was introduced by commit > f0c0b2b808f2 ("change zonelist order: zonelist order selection logic"). > > Later, commit c9bff3eebc09 ("mm, page_alloc: rip out ZONELIST_ORDER_ZONE") > removed build_zonelists_in_zone_order() but left its comment behind. > > Subsequently, commit 9d3be21bf9c0 ("mm, page_alloc: simplify zonelist > initialization") moved the node_order variable into build_zonelists(), > making the comment originally belonged to build_zonelists_in_zone_order() > appear as if it were part of build_zonelists(). > > ... > > --- a/mm/page_alloc.c > +++ b/mm/page_alloc.c > @@ -5161,13 +5161,6 @@ static void build_thisnode_zonelists(pg_data_t *pgdat) > zonerefs->zone_idx = 0; > } > > -/* > - * Build zonelists ordered by zone and nodes within zones. > - * This results in conserving DMA zone[s] until all Normal memory is > - * exhausted, but results in overflowing to remote node while memory > - * may still exist in local DMA zone. > - */ > - Yes, it's not obvious which code this comment is telling us about. I do wonder if the information in this comment could be updated and moved somewhere more appropriate, rather than simply removing it. Oh well, not very important.