From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 CB09F4963B6 for ; Tue, 4 Aug 2026 17:53:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785865999; cv=none; b=OqSEuSBz1uKTxF1CYyTW8sffm6bo/XI9eLIsVT1Oh3XsY+fM41oVvNKnewtEno2pAq3njHyDRNsstb4DNs0uSDdN9RsN8Lj/4h6c62b5uUwVqGA7psjXWZCrxF+rIjNTmoeuy7lNB88Bm/80cgiQOOZtP9PHC2lTaL+9gmcZCpg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785865999; c=relaxed/simple; bh=2zdpcmKB9hx8ycME6+1fFauUyc3zsh9HhXxSWsm0fDY=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=l7u6FUASmvEBN04HMjCdK9Xbwm4Os8a8Qd+c7CWyUVXkbBdQOWsMJjKZl//6pHg1nN1M9qR24mddLh4y3EgnfGXF0YTLLueG30FmQJqejAOnoo8F71Qk2Tu/jA/sa7GP1J0zZdkazbtMFtQc1wnNrkGZMDVMFexkWwcB4yk4C34= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=eiND0nZ7; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="eiND0nZ7" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0E3371F000E9; Tue, 4 Aug 2026 17:53:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1785865988; bh=rCQda7GIREwS7Ugf4K6MkCMcqaAlbBlFYJL+uIOsp1c=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=eiND0nZ7/c2SQVv+amaQov7p1Vb7sl4KP0hRfdwmjSF9qs2HQznazIRFfDYsnEzZt PoKe49cELuSX3J3t6yQ2n4oEegCCkSEoHEY6GMv0V9Vb+8l3+LlNS/A3365zRoruC7 sq8VH7NYD1Kd+FURl3HInsqztBX5gsVQxszKYw4T2AXpWuD+OvquzQKjYQP/eRjiKm 2YZWOVkIbRITMGBXt/nwAI02Sy2NYIf8kOACXRLALruwcG9xIFqN+NQghIZbnxuQcp 0fmOJwJjbKshI73BlaOEnhiVFOdKUagHCnGtnbycjhiY2stNG7Qdi8NVlPiWYYqkWg npkDjk2G1XHmw== Date: Tue, 4 Aug 2026 19:53:04 +0200 From: Ingo Molnar To: Guo Chaohong Cc: peterz@infradead.org, tim.c.chen@linux.intel.com, bp@alien8.de, x86@kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/2] x86/cpu/hygon: Introduce macros for hygon family numbers Message-ID: References: <20260803051248.3684453-1-guochaohong@open-hieco.net> <9f99123f-25be-440d-a5c1-9e213c8e8f3f@open-hieco.net> 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=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <9f99123f-25be-440d-a5c1-9e213c8e8f3f@open-hieco.net> * Guo Chaohong wrote: > hi, Ingo, > > > Hygon model 7 CPUs have either 4 or 6 dies. All 6‑die variants share the > same interconnect topology. > The Hygon‑4G family includes several model numbers, not just model 7. The > 3‑series CPUs are designed > for desktop/workstation use and are only available in single‑socket systems. > > The following is a summary of key Hygon models: > > Model Name   Cores / Threads    Clock Speed   Target Segment           Model > Number > 7447V               96 / 192               ~2.6 GHz Enterprise / Cloud > Server     7 > 7490H              96 / 192                —  High‑Density Server            >  7 (now 7446) > 7490                 64 / 128               2.7 GHz  Enterprise Serve        >            4 > 7470                 48 / 96                  —  Enterprise Server          >         4 > > Therefore, we will restrict this patch to apply only to model 7 CPUs that > have 6 dies on a multi‑socket > system and add sched domains topology after the change into commit message  > in the V2 patch. Understood - but my point is that the "HYGON_7447V" symbol name is inaccurate: +#define HYGON_F18_M07 HFM(0x18, 7) + +#define HYGON_7447V HYGON_F18_M07 Note how 'HYGON_7447V' also covers 7490H/7446. IMHO it will be less confusing if you skip the HYGON_7447V interim symbol and just use HYGON_F18_M07 in arch_sched_node_distance(), and add a comment that clarifies that the additional conditions basically filter for the 7447V variant. Or if you want a clean 7447V enumeration function, add it as an inline function and use that in arch_sched_node_distance(). Both approaches would be acceptable. Thanks, Ingo