From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by mx.groups.io with SMTP id smtpd.web12.3909.1611214120614694532 for ; Wed, 20 Jan 2021 23:28:40 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 134.134.136.24, mailfrom: yun.lou@intel.com) IronPort-SDR: 4FwzLXTVnxU3jspeTBO5c8xGuH1eDpD0rKXSg5VWXpqffcjJpRIWkrf+kzO04IpK6+g/dM1SxJ /55kRIhNSobw== X-IronPort-AV: E=McAfee;i="6000,8403,9870"; a="179380902" X-IronPort-AV: E=Sophos;i="5.79,363,1602572400"; d="scan'208";a="179380902" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Jan 2021 23:28:39 -0800 IronPort-SDR: G4h52mpPd5Rdfa/gVCPTmXbfQqeivMzGsfT7+CfW97xfO/H7C7EIPZ3Mfm5GlyVRXN6b9XXduq tAJH5lQE0M7Q== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.79,363,1602572400"; d="scan'208";a="385194710" Received: from shwdeopenlab102.ccr.corp.intel.com ([10.239.183.61]) by orsmga008.jf.intel.com with ESMTP; 20 Jan 2021 23:28:37 -0800 From: "Jason Lou" To: devel@edk2.groups.io Cc: Jason , Michael D Kinney , Liming Gao , Zhiguang Liu , Ray Ni , Eric Dong , Laszlo Ersek , Rahul Kumar Subject: [PATCH v2 1/1] MdePkg/Cpuid.h: Change and add some macro definitions. Date: Thu, 21 Jan 2021 15:28:30 +0800 Message-Id: <20210121072830.4083-1-yun.lou@intel.com> X-Mailer: git-send-email 2.28.0.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3105 Change and add some macro definitions about CPUID_HYBRID_INFORMATION Leaf(1Ah). Signed-off-by: Jason Lou Cc: Michael D Kinney Cc: Liming Gao Cc: Zhiguang Liu Cc: Ray Ni Cc: Eric Dong Cc: Laszlo Ersek Cc: Rahul Kumar --- UefiCpuPkg/Library/CpuCacheInfoLib/CpuCacheInfoLib.c | 2 +- MdePkg/Include/Register/Intel/Cpuid.h | 17 +++++++++++++---- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/UefiCpuPkg/Library/CpuCacheInfoLib/CpuCacheInfoLib.c b/UefiCpu= Pkg/Library/CpuCacheInfoLib/CpuCacheInfoLib.c index 6b87be261acf..d1f9830c91e7 100644 --- a/UefiCpuPkg/Library/CpuCacheInfoLib/CpuCacheInfoLib.c +++ b/UefiCpuPkg/Library/CpuCacheInfoLib/CpuCacheInfoLib.c @@ -175,7 +175,7 @@ CpuCacheInfoCollectCoreAndCacheData ( //=0D Context->ProcessorInfo[ProcessorIndex].CoreType =3D 0;=0D if (CpuidMaxInput >=3D CPUID_HYBRID_INFORMATION) {=0D - AsmCpuidEx (CPUID_HYBRID_INFORMATION, CPUID_HYBRID_INFORMATION_SUB_LEA= F, &NativeModelIdAndCoreTypeEax.Uint32, NULL, NULL, NULL);=0D + AsmCpuidEx (CPUID_HYBRID_INFORMATION, CPUID_HYBRID_INFORMATION_MAIN_LE= AF, &NativeModelIdAndCoreTypeEax.Uint32, NULL, NULL, NULL);=0D Context->ProcessorInfo[ProcessorIndex].CoreType =3D (UINT8) NativeMode= lIdAndCoreTypeEax.Bits.CoreType;=0D }=0D =0D diff --git a/MdePkg/Include/Register/Intel/Cpuid.h b/MdePkg/Include/Registe= r/Intel/Cpuid.h index dd1b64a1e50b..a670ab436c37 100644 --- a/MdePkg/Include/Register/Intel/Cpuid.h +++ b/MdePkg/Include/Register/Intel/Cpuid.h @@ -3601,7 +3601,7 @@ typedef union { CPUID Hybrid Information Enumeration Leaf=0D =0D @param EAX CPUID_HYBRID_INFORMATION (0x1A)=0D - @param ECX CPUID_HYBRID_INFORMATION_SUB_LEAF (0x00).=0D + @param ECX CPUID_HYBRID_INFORMATION_MAIN_LEAF (0x00).=0D =0D @retval EAX Enumerates the native model ID and core type described=0D by the type CPUID_NATIVE_MODEL_ID_AND_CORE_TYPE_EAX=0D @@ -3615,7 +3615,7 @@ typedef union { =0D AsmCpuidEx (=0D CPUID_HYBRID_INFORMATION,=0D - CPUID_HYBRID_INFORMATION_SUB_LEAF,=0D + CPUID_HYBRID_INFORMATION_MAIN_LEAF,=0D &Eax, NULL, NULL, NULL=0D );=0D @endcode=0D @@ -3626,11 +3626,11 @@ typedef union { ///=0D /// CPUID Hybrid Information Enumeration sub-leaf=0D ///=0D -#define CPUID_HYBRID_INFORMATION_SUB_LEAF 0x= 00=0D +#define CPUID_HYBRID_INFORMATION_MAIN_LEAF 0x= 00=0D =0D /**=0D CPUID Hybrid Information EAX for CPUID leaf #CPUID_HYBRID_INFORMATION,=0D - sub-leaf #CPUID_HYBRID_INFORMATION_SUB_LEAF.=0D + sub-leaf #CPUID_HYBRID_INFORMATION_MAIN_LEAF.=0D **/=0D typedef union {=0D ///=0D @@ -3657,6 +3657,15 @@ typedef union { UINT32 Uint32;=0D } CPUID_NATIVE_MODEL_ID_AND_CORE_TYPE_EAX;=0D =0D +///=0D +/// @{ Define value for CPUID_NATIVE_MODEL_ID_AND_CORE_TYPE_EAX.CoreType=0D +///=0D +#define CPUID_CORE_TYPE_INTEL_ATOM 0x= 20=0D +#define CPUID_CORE_TYPE_INTEL_CORE 0x= 40=0D +///=0D +/// @}=0D +///=0D +=0D =0D /**=0D CPUID V2 Extended Topology Enumeration Leaf=0D --=20 2.28.0.windows.1