]> git.proxmox.com Git - mirror_edk2.git/blobdiff - IntelSiliconPkg/Feature/Capsule/MicrocodeUpdateDxe/MicrocodeUpdate.h
IntelSiliconPkg MicrocodeUpdateDxe: Honor FIT table
[mirror_edk2.git] / IntelSiliconPkg / Feature / Capsule / MicrocodeUpdateDxe / MicrocodeUpdate.h
index 9dc306324e627fe590ad3fb95f620ff73baaa941..3f92c517a91cd8e758ae9c8b9ff1fce6e2c951b7 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   Microcode update header file.\r
 \r
-  Copyright (c) 2016, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2016 - 2018, Intel Corporation. All rights reserved.<BR>\r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
   which accompanies this distribution.  The full text of the license may be found at\r
@@ -20,6 +20,8 @@
 #include <Guid/SystemResourceTable.h>\r
 #include <Guid/MicrocodeFmp.h>\r
 \r
+#include <IndustryStandard/FirmwareInterfaceTable.h>\r
+\r
 #include <Protocol/FirmwareManagement.h>\r
 #include <Protocol/MpService.h>\r
 \r
@@ -57,6 +59,13 @@ typedef struct {
   BOOLEAN                InUse;\r
 } MICROCODE_INFO;\r
 \r
+typedef struct {\r
+  CPU_MICROCODE_HEADER   *MicrocodeEntryPoint;\r
+  UINTN                  TotalSize;\r
+  BOOLEAN                InUse;\r
+  BOOLEAN                Empty;\r
+} FIT_MICROCODE_INFO;\r
+\r
 typedef struct {\r
   UINTN                  CpuIndex;\r
   UINT32                 ProcessorSignature;\r
@@ -86,11 +95,13 @@ struct _MICROCODE_FMP_PRIVATE_DATA {
   UINTN                                BspIndex;\r
   UINTN                                ProcessorCount;\r
   PROCESSOR_INFO                       *ProcessorInfo;\r
+  UINT32                               FitMicrocodeEntryCount;\r
+  FIT_MICROCODE_INFO                   *FitMicrocodeInfo;\r
 };\r
 \r
 typedef struct _MICROCODE_FMP_PRIVATE_DATA  MICROCODE_FMP_PRIVATE_DATA;\r
 \r
-#define MICROCODE_FMP_LAST_ATTEMPT_VARIABLE_NAME  L"MicrocodeLastAttempVar"\r
+#define MICROCODE_FMP_LAST_ATTEMPT_VARIABLE_NAME  L"MicrocodeLastAttemptVar"\r
 \r
 /**\r
   Returns a pointer to the MICROCODE_FMP_PRIVATE_DATA structure from the input a as Fmp.\r
@@ -305,7 +316,7 @@ FmpGetImageInfo (
   @retval EFI_INVALID_PARAMETER  The Image was NULL.\r
   @retval EFI_NOT_FOUND          The current image is not copied to the buffer.\r
   @retval EFI_UNSUPPORTED        The operation is not supported.\r
-  @retval EFI_SECURITY_VIOLATIO  The operation could not be performed due to an authentication failure.\r
+  @retval EFI_SECURITY_VIOLATION The operation could not be performed due to an authentication failure.\r
 \r
 **/\r
 EFI_STATUS\r
@@ -360,7 +371,7 @@ FmpGetImage (
   @retval EFI_ABORTED            The operation is aborted.\r
   @retval EFI_INVALID_PARAMETER  The Image was NULL.\r
   @retval EFI_UNSUPPORTED        The operation is not supported.\r
-  @retval EFI_SECURITY_VIOLATIO  The operation could not be performed due to an authentication failure.\r
+  @retval EFI_SECURITY_VIOLATION The operation could not be performed due to an authentication failure.\r
 \r
 **/\r
 EFI_STATUS\r
@@ -392,7 +403,7 @@ FmpSetImage (
   @retval EFI_SUCCESS            The image was successfully checked.\r
   @retval EFI_INVALID_PARAMETER  The Image was NULL.\r
   @retval EFI_UNSUPPORTED        The operation is not supported.\r
-  @retval EFI_SECURITY_VIOLATIO  The operation could not be performed due to an authentication failure.\r
+  @retval EFI_SECURITY_VIOLATION The operation could not be performed due to an authentication failure.\r
 \r
 **/\r
 EFI_STATUS\r
@@ -476,7 +487,7 @@ FmpGetPackageInfo (
   @retval EFI_INVALID_PARAMETER  The PackageVersionName length is longer than the value\r
                                  returned in PackageVersionNameMaxLen.\r
   @retval EFI_UNSUPPORTED        The operation is not supported.\r
-  @retval EFI_SECURITY_VIOLATIO  The operation could not be performed due to an authentication failure.\r
+  @retval EFI_SECURITY_VIOLATION The operation could not be performed due to an authentication failure.\r
 \r
 **/\r
 EFI_STATUS\r