* [PATCH] IntelSiliconPkg/ShadowMicrocode: Fix build failure
@ 2021-04-12 8:45 Ni, Ray
2021-04-12 15:19 ` Chaganty, Rangasai V
0 siblings, 1 reply; 2+ messages in thread
From: Ni, Ray @ 2021-04-12 8:45 UTC (permalink / raw)
To: devel; +Cc: Rangasai V Chaganty
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
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] IntelSiliconPkg/ShadowMicrocode: Fix build failure
2021-04-12 8:45 [PATCH] IntelSiliconPkg/ShadowMicrocode: Fix build failure Ni, Ray
@ 2021-04-12 15:19 ` Chaganty, Rangasai V
0 siblings, 0 replies; 2+ messages in thread
From: Chaganty, Rangasai V @ 2021-04-12 15:19 UTC (permalink / raw)
To: Ni, Ray, devel@edk2.groups.io
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
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-04-12 15:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-04-12 8:45 [PATCH] IntelSiliconPkg/ShadowMicrocode: Fix build failure Ni, Ray
2021-04-12 15:19 ` Chaganty, Rangasai V
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox