From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out28-145.mail.aliyun.com (out28-145.mail.aliyun.com [115.124.28.145]) (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 0548C2DCF45 for ; Wed, 17 Jun 2026 02:39:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=115.124.28.145 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781663986; cv=none; b=IFvJatA6EouUVA9SgZKqH6pivbdq/WMLq3boI5yvzH+sx/Tj6uppa+bSb7LUKITdTlRf3Hg6ZgDN1vVK/jH6G3zRfUP0NNK5msVAV3GeXAHUkMipvN62a9Xyek8SlbbFXs/s/9I/qWu4t5Q/uix1NB5V4ZQvWCsctZTa4NZSg80= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781663986; c=relaxed/simple; bh=IIR/PxF/04UbLelK+g+mbbmVpUY6/0t4Yy1JhmoaggY=; h=Message-ID:Date:MIME-Version:From:Subject:To:Cc:References: In-Reply-To:Content-Type; b=mF+yC83nIhUlXwoakTpz8kHd7hvxo6vO8HHC6iSbwvdK2aixRZUL6Dp/jzNRgC1w15QpCGO+yxWGN0RGjrfpH/7/3/9bDgaKMxvwAJSDER5aXUNwkwYeqmGUDeO6PT8VCtkYtQKSndxmo7Nbcu0BTdCYKb+LQlGxpMZwAiNuyGk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=open-hieco.net; spf=pass smtp.mailfrom=open-hieco.net; arc=none smtp.client-ip=115.124.28.145 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=open-hieco.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=open-hieco.net X-Alimail-AntiSpam:AC=CONTINUE;BC=0.1665189|-1;CH=green;DM=|CONTINUE|false|;DS=CONTINUE|ham_enroll_verification|0.0212793-0.00552252-0.973198;FP=17134343966393446422|0|0|0|0|-1|-1|-1;HT=maildocker-contentspam033068005250;MF=fuhao@open-hieco.net;NM=1;PH=DS;RN=10;RT=10;SR=0;TI=SMTPD_---.i-EX6US_1781663657; Received: from 172.25.21.212(mailfrom:fuhao@open-hieco.net fp:SMTPD_---.i-EX6US_1781663657 cluster:ay29) by smtp.aliyun-inc.com; Wed, 17 Jun 2026 10:34:18 +0800 Message-ID: <3462d834-3862-4dce-acd6-e61de8144666@open-hieco.net> Date: Wed, 17 Jun 2026 10:34:16 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird From: Fu Hao Subject: Re: [PATCH v3 1/7] x86/cpu/hygon: Adjust the die_id and logical_die_id for Hygon models 0x4 through 0x8 To: Dave Hansen , puwen@hygon.cn, tglx@kernel.org, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com, x86@kernel.org, hpa@zytor.com Cc: linux-kernel@vger.kernel.org, tingyin.duan@gmail.com References: <8d0f20314a4fb95111479166b5397e34e382a3f0.1781523812.git.fuhao@open-hieco.net> <6277cd17-ee61-4682-b58e-f957eecb0b58@intel.com> Content-Language: en-US In-Reply-To: <6277cd17-ee61-4682-b58e-f957eecb0b58@intel.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 6/16/2026 11:25 PM, Dave Hansen wrote: > On 6/16/26 00:18, Fu Hao wrote: >> 1. On AMD, this function retrieves amd_node_id, which is an AMD-specific >> Node ID. We suspect this is kept for CDD compatibility, but its >> semantics differ from Hygon's requirements. > > What are those requirements? We need to accurately obtain both the physical die ID and the logical die ID. It is important to note that physical die IDs may be non- contiguous​ in multi-socket interconnect products. In Hygon CPU design, the NodeId field of CPUID leaf 0x8000001e (ECX) is now fixed to represent the socket ID and die ID, allocated as 4 bits each: socket ID = NodeId[7:4], die ID = NodeId[3:0]. This format diverges from AMD's definition of the same leaf. Since the bit allocation differs, we cannot reuse AMD's parsing logic. -- Regards, Fu Hao