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 E8C4132E72A for ; Mon, 5 Jan 2026 09:35:01 +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=1767605703; cv=none; b=Y5v4YOuITjr7trikFJDoqS94PqdhttqzQN+OBy58lXi/jrrbxxDXelzuQKTcE2c5FZMfP1sT+/9c0/LfITHcK1s2M+MfD/ywnGGHb51NMPOGoYSNNsWTLtY4vwbzo4rzm9foZXvy9PQMc8iD+MRD1teAGGZaMZBdRZNaWmipP68= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767605703; c=relaxed/simple; bh=bn7mM9cOL8od9/KRNKPTS1zEKSNile2RiMjyI0hZBf8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Gm8x3qgokcUP34WeoNunCsgnPLHcxmLA7TVFxSqajqROokeXBJMDqt/vJ6EFuqnu0Vy7Eh1xKMqM9COclOVxzKrnj5ZZ6xoZyjluQWsPCTLPnjYqGQbytixinx5uHZOt9gBA7boPiGtan82I+CsGH9ERalDWinpNzszGawJCpsM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=YVtYl43N; 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="YVtYl43N" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 54D20C116D0; Mon, 5 Jan 2026 09:34:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1767605701; bh=bn7mM9cOL8od9/KRNKPTS1zEKSNile2RiMjyI0hZBf8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=YVtYl43NMWF7kgcJE4xufMXZZpjTsLLjkQnuZPgsgz9d/YZYL0qm77oYxQKBKmAJK F8zv+f6PCteGmpflvD6m59enuxDzGihjhl7qfdkJty+HSTNDrAMD5mr9pjliYmINBC hsaS6U1Q0UYvf5BbhyfOkEeQsLKzO+drcJwSM5StyTQ9Ot2oK47ZG35crN3OZAMpYQ VD22esVWApTUvNTCqoz/sXRfjKkQWF/9mkhWBP71WZnQ8wooORUd3GzY8zuRLHYMi6 SJw8oilCe9pXK5NNnDv37f5mv303+5J8tb3Kom1K57gWRSu1NgmyPkSHQO8EMmGhVV eh3tSWdZ3H7iw== Date: Mon, 5 Jan 2026 11:34:55 +0200 From: Mike Rapoport To: Cui Chao Cc: Andrew Morton , Joanthan Cameron , wangyinfeng@phytium.com.cn, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm: numa_memblks: Identify the accurate NUMA ID of CFMW Message-ID: References: <20251230092750.856060-1-cuichao1753@phytium.com.cn> 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=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: On Mon, Jan 05, 2026 at 10:38:30AM +0800, Cui Chao wrote: > Hi, > > Thank you for your review. > > On 12/30/2025 11:18 PM, Mike Rapoport wrote: > > Hi, > > > > On Tue, Dec 30, 2025 at 05:27:50PM +0800, Cui Chao wrote: > > > In some physical memory layout designs, the address space of CFMW > > > resides between multiple segments of system memory belonging to > > > the same NUMA node. In numa_cleanup_meminfo, these multiple segments > > > of system memory are merged into a larger numa_memblk. When > > > identifying which NUMA node the CFMW belongs to, it may be incorrectly > > > assigned to the NUMA node of the merged system memory. To address this > > Can you please provide an example of such memory layout? > > Example memory layout: > > Physical address space: >     0x00000000 - 0x1FFFFFFF  System RAM (node0) >     0x20000000 - 0x2FFFFFFF  CXL CFMW (node2) >     0x40000000 - 0x5FFFFFFF  System RAM (node0) >     0x60000000 - 0x7FFFFFFF  System RAM (node1) > > After numa_cleanup_meminfo, the two node0 segments are merged into one: >     0x00000000 - 0x5FFFFFFF  System RAM (node0)  // CFMW is inside this > range >     0x60000000 - 0x7FFFFFFF  System RAM (node1) > > So the CFMW (0x20000000-0x2FFFFFFF) will be incorrectly assigned to node0. Can you please add this example to the changelog? > > > scenario, accurately identifying the correct NUMA node can be achieved > > > by checking whether the region belongs to both numa_meminfo and > > > numa_reserved_meminfo. > > > > > > Signed-off-by: Cui Chao -- Sincerely yours, Mike.