.../Feature/ShadowMicrocode/ShadowMicrocodePei.c | 3 +-- Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc | 1 + 2 files changed, 2 insertions(+), 2 deletions(-)
The commit 7e4c6f982a0accd5aa86337b46d20199db989aeb
updated ShadowMicrocode module to consume MicrocodeLib.
But the change caused the build failure.
The patch fixed the build failure and also verified the change
in real platform.
Signed-off-by: Ray Ni <ray.ni@intel.com>
Cc: Rangasai V Chaganty <rangasai.v.chaganty@intel.com>
---
.../Feature/ShadowMicrocode/ShadowMicrocodePei.c | 3 +--
Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc | 1 +
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Silicon/Intel/IntelSiliconPkg/Feature/ShadowMicrocode/ShadowMicrocodePei.c b/Silicon/Intel/IntelSiliconPkg/Feature/ShadowMicrocode/ShadowMicrocodePei.c
index 4e4b69a0ca..7f4a3f8fbd 100644
--- a/Silicon/Intel/IntelSiliconPkg/Feature/ShadowMicrocode/ShadowMicrocodePei.c
+++ b/Silicon/Intel/IntelSiliconPkg/Feature/ShadowMicrocode/ShadowMicrocodePei.c
@@ -291,7 +291,6 @@ ShadowMicrocode (
UINTN MaxPatchNumber;
CPU_MICROCODE_HEADER *MicrocodeEntryPoint;
UINTN PatchCount;
- UINTN DataSize;
UINTN TotalSize;
UINTN TotalLoadSize;
@@ -342,7 +341,7 @@ ShadowMicrocode (
if (FitEntry[Index].Type == FIT_TYPE_01_MICROCODE) {
MicrocodeEntryPoint = (CPU_MICROCODE_HEADER *) (UINTN) FitEntry[Index].Address;
TotalSize = GetMicrocodeLength (MicrocodeEntryPoint);
- if (IsValidMicrocode (MicrocodeEntryPoint, TotalSize, MicrocodeCpuId, CpuIdCount, FALSE)) {
+ if (IsValidMicrocode (MicrocodeEntryPoint, TotalSize, 0, MicrocodeCpuId, CpuIdCount, FALSE)) {
PatchInfoBuffer[PatchCount].Address = (UINTN) MicrocodeEntryPoint;
PatchInfoBuffer[PatchCount].Size = TotalSize;
TotalLoadSize += TotalSize;
diff --git a/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc b/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc
index edc79c9b9c..5e0de7e19a 100644
--- a/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc
+++ b/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc
@@ -39,6 +39,7 @@
MicrocodeFlashAccessLib|IntelSiliconPkg/Feature/Capsule/Library/MicrocodeFlashAccessLibNull/MicrocodeFlashAccessLibNull.inf
PeiGetVtdPmrAlignmentLib|IntelSiliconPkg/Library/PeiGetVtdPmrAlignmentLib/PeiGetVtdPmrAlignmentLib.inf
TpmMeasurementLib|MdeModulePkg/Library/TpmMeasurementLibNull/TpmMeasurementLibNull.inf
+ MicrocodeLib|UefiCpuPkg/Library/MicrocodeLib/MicrocodeLib.inf
[LibraryClasses.common.PEIM]
PeimEntryPoint|MdePkg/Library/PeimEntryPoint/PeimEntryPoint.inf
--
2.27.0.windows.1
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#73938): https://edk2.groups.io/g/devel/message/73938
Mute This Topic: https://groups.io/mt/82033444/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-
Reviewed-by: Sai Chaganty <rangasai.v.chaganty@intel.com> -----Original Message----- From: Ni, Ray <ray.ni@intel.com> Sent: Monday, April 12, 2021 1:45 AM To: devel@edk2.groups.io Cc: Chaganty, Rangasai V <rangasai.v.chaganty@intel.com> Subject: [PATCH] IntelSiliconPkg/ShadowMicrocode: Fix build failure The commit 7e4c6f982a0accd5aa86337b46d20199db989aeb updated ShadowMicrocode module to consume MicrocodeLib. But the change caused the build failure. The patch fixed the build failure and also verified the change in real platform. Signed-off-by: Ray Ni <ray.ni@intel.com> Cc: Rangasai V Chaganty <rangasai.v.chaganty@intel.com> --- .../Feature/ShadowMicrocode/ShadowMicrocodePei.c | 3 +-- Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Silicon/Intel/IntelSiliconPkg/Feature/ShadowMicrocode/ShadowMicrocodePei.c b/Silicon/Intel/IntelSiliconPkg/Feature/ShadowMicrocode/ShadowMicrocodePei.c index 4e4b69a0ca..7f4a3f8fbd 100644 --- a/Silicon/Intel/IntelSiliconPkg/Feature/ShadowMicrocode/ShadowMicrocodePei.c +++ b/Silicon/Intel/IntelSiliconPkg/Feature/ShadowMicrocode/ShadowMicroc +++ odePei.c @@ -291,7 +291,6 @@ ShadowMicrocode ( UINTN MaxPatchNumber; CPU_MICROCODE_HEADER *MicrocodeEntryPoint; UINTN PatchCount;- UINTN DataSize; UINTN TotalSize; UINTN TotalLoadSize; @@ -342,7 +341,7 @@ ShadowMicrocode ( if (FitEntry[Index].Type == FIT_TYPE_01_MICROCODE) { MicrocodeEntryPoint = (CPU_MICROCODE_HEADER *) (UINTN) FitEntry[Index].Address; TotalSize = GetMicrocodeLength (MicrocodeEntryPoint);- if (IsValidMicrocode (MicrocodeEntryPoint, TotalSize, MicrocodeCpuId, CpuIdCount, FALSE)) {+ if (IsValidMicrocode (MicrocodeEntryPoint, TotalSize, 0, MicrocodeCpuId, CpuIdCount, FALSE)) { PatchInfoBuffer[PatchCount].Address = (UINTN) MicrocodeEntryPoint; PatchInfoBuffer[PatchCount].Size = TotalSize; TotalLoadSize += TotalSize;diff --git a/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc b/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc index edc79c9b9c..5e0de7e19a 100644 --- a/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc +++ b/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc @@ -39,6 +39,7 @@ MicrocodeFlashAccessLib|IntelSiliconPkg/Feature/Capsule/Library/MicrocodeFlashAccessLibNull/MicrocodeFlashAccessLibNull.inf PeiGetVtdPmrAlignmentLib|IntelSiliconPkg/Library/PeiGetVtdPmrAlignmentLib/PeiGetVtdPmrAlignmentLib.inf TpmMeasurementLib|MdeModulePkg/Library/TpmMeasurementLibNull/TpmMeasurementLibNull.inf+ MicrocodeLib|UefiCpuPkg/Library/MicrocodeLib/MicrocodeLib.inf [LibraryClasses.common.PEIM] PeimEntryPoint|MdePkg/Library/PeimEntryPoint/PeimEntryPoint.inf-- 2.27.0.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#73965): https://edk2.groups.io/g/devel/message/73965 Mute This Topic: https://groups.io/mt/82033444/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=-=-=-=-=-=-=-=-=-=-=-
© 2016 - 2024 Red Hat, Inc.