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 8EE82399002 for ; Wed, 29 Apr 2026 06:54:23 +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=1777445663; cv=none; b=HZ7XRmJx9xX578CNpdAuH6DKf1nCIw325ENUAON/rMMWd7ges5WRN88yc3lG91Hc/2GRkE3akCWbmAIdnd3XyA2+/i1SNoXHx3+9CL4aWQ2QjUTgg5QW73WK9bWJTDCDPoZdoaKCASRgprxSQJDPJX1NXLoS6W4m221Dxx50l08= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777445663; c=relaxed/simple; bh=VZhtBpxtU8HwWnxxe7mElHzRTUbl86uTSwoh/+EFdzI=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=AHErvrpD31DStZM5gM6PaaaiHZasJ8na2771tyitoIcDv3NyrpgzUQGz1zdrbE1haLvVrwoG3FN08LqZlUpcFMdn2NMpHtlpGetDVD0n9raLLIGMahFmW6DThJ9RNwhokWGU1hr4kS1M4SAyHigKa19Pgveb+3XIZOynWBBRKGk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=QjYezp2W; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="QjYezp2W" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3CC19C19425; Wed, 29 Apr 2026 06:54:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1777445663; bh=VZhtBpxtU8HwWnxxe7mElHzRTUbl86uTSwoh/+EFdzI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=QjYezp2WABk/jL3hRnX8uE/19RtCgpxR/18bX0qbACdrN/vPKi9wmghBVgVkeuWT/ otyKR5y0W7LUENnkCNaLS0Q5nP+qdpr2oHThPhrcsIwdPc813ychE4gYb8ty6jTyOj 377di99Rd/I+crzDzejN9wS+Xb8qJvJXFBxigPqEpPhR5VfsksF43m6a7TQXKsH9Ji 3/906mdHOKcTMJDMgTKF8SjUVa3IUg5+1/lecu5Cel1eiMVkfoc4DEOJMAJTgF9TvD TDEnySeBIEbY9lUAbCWopWghVONqeUtpXbkvfE8+MpJl626rRTUpPPSIWzDdzwxzNj KaxcWyxQWLGCA== Date: Wed, 29 Apr 2026 08:54:13 +0200 From: Mike Rapoport To: Muchun Song Cc: Muchun Song , Andrew Morton , David Hildenbrand , Oscar Salvador , Michael Ellerman , Madhavan Srinivasan , Lorenzo Stoakes , "Liam R . Howlett" , Vlastimil Babka , Suren Baghdasaryan , Michal Hocko , Nicholas Piggin , Christophe Leroy , aneesh.kumar@linux.ibm.com, joao.m.martins@oracle.com, linux-mm@kvack.org, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 10/49] mm: move subsection_map_init() into sparse_init() Message-ID: References: <20260405125240.2558577-1-songmuchun@bytedance.com> <20260405125240.2558577-11-songmuchun@bytedance.com> 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-Disposition: inline In-Reply-To: On Wed, Apr 29, 2026 at 11:06:15AM +0800, Muchun Song wrote: > > > > On Apr 28, 2026, at 15:06, Mike Rapoport wrote: > > > > On Sun, Apr 05, 2026 at 08:52:01PM +0800, Muchun Song wrote: > >> Move the initialization of the subsection map from free_area_init() > >> into sparse_init(). This encapsulates the logic within the sparse > >> memory initialization code. > >> > >> Signed-off-by: Muchun Song > > > > Acked-by: Mike Rapoport (Microsoft) > > Thanks. > > > > >> --- > >> mm/internal.h | 5 ++--- > >> mm/mm_init.c | 10 ++-------- > >> mm/sparse-vmemmap.c | 11 ++++++++++- > >> mm/sparse.c | 1 + > >> 4 files changed, 15 insertions(+), 12 deletions(-) > >> > >> diff --git a/mm/internal.h b/mm/internal.h > >> index edb1c04d0617..d70075d0e788 100644 > >> --- a/mm/internal.h > >> +++ b/mm/internal.h > >> @@ -1004,10 +1004,9 @@ static inline void sparse_init(void) {} > >> * mm/sparse-vmemmap.c > >> */ > >> #ifdef CONFIG_SPARSEMEM_VMEMMAP > >> -void sparse_init_subsection_map(unsigned long pfn, unsigned long nr_pages); > >> +void sparse_init_subsection_map(void); > >> #else > >> -static inline void sparse_init_subsection_map(unsigned long pfn, > >> - unsigned long nr_pages) > >> +static inline void sparse_init_subsection_map(void) > >> { > >> } > >> #endif /* CONFIG_SPARSEMEM_VMEMMAP */ > > > > I side note: we might want to split out mm/sparse.h and also move some > > declarations from include/linux/mmzone.h there. > > I think we can do that in a separate series for cleanup only. Sure, that's what I meant too. > Thanks. > > -- Sincerely yours, Mike.