]> git.proxmox.com Git - mirror_edk2.git/blobdiff - UefiCpuPkg/Include/Library/RegisterCpuFeaturesLib.h
UefiCpuPkg/CpuFeature: Introduce First to indicate 1st unit.
[mirror_edk2.git] / UefiCpuPkg / Include / Library / RegisterCpuFeaturesLib.h
index be14a92b352d3ed220589337f02de9f36c488dc0..27bd2f6b48dc4b47d75733ea6a092bd8cd1fc48d 100644 (file)
 #define CPU_FEATURE_END                             MAX_UINT32\r
 /// @}\r
 \r
+///\r
+/// The bit field to indicate whether the processor is the first in its parent scope.\r
+///\r
+typedef struct {\r
+  //\r
+  // Set to 1 when current processor is the first thread in the core it resides in.\r
+  //\r
+  UINT32 Thread   : 1;\r
+  //\r
+  // Set to 1 when current processor is a thread of the first core in the module it resides in.\r
+  //\r
+  UINT32 Core     : 1;\r
+  //\r
+  // Set to 1 when current processor is a thread of the first module in the tile it resides in.\r
+  //\r
+  UINT32 Module   : 1;\r
+  //\r
+  // Set to 1 when current processor is a thread of the first tile in the die it resides in.\r
+  //\r
+  UINT32 Tile     : 1;\r
+  //\r
+  // Set to 1 when current processor is a thread of the first die in the package it resides in.\r
+  //\r
+  UINT32 Die      : 1;\r
+  //\r
+  // Set to 1 when current processor is a thread of the first package in the system.\r
+  //\r
+  UINT32 Package  : 1;\r
+  UINT32 Reserved : 26;\r
+} REGISTER_CPU_FEATURE_FIRST_PROCESSOR;\r
+\r
 ///\r
 /// CPU Information passed into the SupportFunc and InitializeFunc of the\r
 /// RegisterCpuFeature() library function.  This structure contains information\r
@@ -88,6 +119,11 @@ typedef struct {
   /// The package that the CPU resides\r
   ///\r
   EFI_PROCESSOR_INFORMATION            ProcessorInfo;\r
+\r
+  ///\r
+  /// The bit flag indicating whether the CPU is the first Thread/Core/Module/Tile/Die/Package in its parent scope.\r
+  ///\r
+  REGISTER_CPU_FEATURE_FIRST_PROCESSOR First;\r
   ///\r
   /// The Display Family of the CPU computed from CPUID leaf CPUID_VERSION_INFO\r
   ///\r