diff options
author | Hao A Wu <hao.a.wu@intel.com> | 2019-12-23 10:52:14 +0800 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2020-01-02 03:10:36 +0000 |
commit | 253909974a0e2e9c60fa78e57c0c46fef2877332 (patch) | |
tree | ee501d8198f4ec3fdf96bcf15bf110b921ff1b02 /UefiCpuPkg/Include | |
parent | d786a1723203e91c92615c58d217e35b0d894004 (diff) | |
download | edk2-253909974a0e2e9c60fa78e57c0c46fef2877332.tar.gz edk2-253909974a0e2e9c60fa78e57c0c46fef2877332.tar.bz2 edk2-253909974a0e2e9c60fa78e57c0c46fef2877332.zip |
UefiCpuPkg: Add definitions for EDKII microcode patch HOB
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2430
This commit will add the definitions for EDKII microcode patch HOB.
The intention of adding this HOB is to provide a scheme to store the below
information:
A. The base address and size of the microcode patches that are being
loaded (from flash) into memory;
B. The information of detected microcode patch for each processor within
the system.
The producer of the HOB will be the UefiCpuPkg/MpInitLib (where the load,
detect and apply of the microcode happen). The consumer of the HOB can be
modules that want to detect/apply the microcode patch by themselves again
later during the boot flow.
Cc: Eric Dong <eric.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Siyuan Fu <siyuan.fu@intel.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Signed-off-by: Hao A Wu <hao.a.wu@intel.com>
Reviewed-by: Ray Ni <ray.ni@intel.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>
Diffstat (limited to 'UefiCpuPkg/Include')
-rw-r--r-- | UefiCpuPkg/Include/Guid/MicrocodePatchHob.h | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/UefiCpuPkg/Include/Guid/MicrocodePatchHob.h b/UefiCpuPkg/Include/Guid/MicrocodePatchHob.h new file mode 100644 index 0000000000..2d307fbffb --- /dev/null +++ b/UefiCpuPkg/Include/Guid/MicrocodePatchHob.h @@ -0,0 +1,44 @@ +/** @file
+ The microcode patch HOB is used to store the information of:
+ A. Base address and size of the loaded microcode patches data;
+ B. Detected microcode patch for each processor within system.
+
+ Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
+ SPDX-License-Identifier: BSD-2-Clause-Patent
+
+**/
+
+#ifndef _MICROCODE_PATCH_HOB_H_
+#define _MICROCODE_PATCH_HOB_H_
+
+extern EFI_GUID gEdkiiMicrocodePatchHobGuid;
+
+//
+// The EDKII microcode patch HOB will be produced by MpInitLib and it can be
+// consumed by modules that want to detect/apply microcode patches.
+//
+typedef struct {
+ //
+ // The base address of the microcode patches data after being loaded into
+ // memory.
+ //
+ UINT64 MicrocodePatchAddress;
+ //
+ // The total size of the loaded microcode patches.
+ //
+ UINT64 MicrocodePatchRegionSize;
+ //
+ // The number of processors within the system.
+ //
+ UINT32 ProcessorCount;
+ //
+ // An array with 'ProcessorCount' elements that stores the offset (with
+ // regard to 'MicrocodePatchAddress') of the detected microcode patch
+ // (including the CPU_MICROCODE_HEADER data structure) for each processor.
+ // If no microcode patch is detected for certain processor, the relating
+ // element will be set to MAX_UINT64.
+ //
+ UINT64 ProcessorSpecificPatchOffset[0];
+} EDKII_MICROCODE_PATCH_HOB;
+
+#endif
|