Revert UefiCpuPkg/MpInitLib: Relocate microcode patch fields in CPU_MP_DATA

This reverts commit 88bd066166.

REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2465

Commit 88bd066166 relocates the 'MicrocodePatchAddress' and
'MicrocodePatchRegionSize' fields in structure CPU_MP_DATA to ensure that
they can be properly passed between different architectures.

However, such change is not backward compatible with the scenario like
pre-existing binaries such as FSP. These binaries are built when the code
base has a different version of the CPU_MP_DATA structure definition. This
may cause issues when accessing the 'MicrocodePatchAddress' and
'MicrocodePatchRegionSize' fields, since their offsets are different
(between PEI phase in the FSP binaries and DXE phase in current code
implementation).

Cc: Michael Kubacki <michael.a.kubacki@intel.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Signed-off-by: Hao A Wu <hao.a.wu@intel.com>
Acked-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Ray Ni <ray.ni@intel.com>
This commit is contained in:
Hao A Wu 2020-01-16 09:30:12 +08:00 committed by mergify[bot]
parent ccb4c38a50
commit d148a178c1
1 changed files with 2 additions and 2 deletions

View File

@ -219,8 +219,6 @@ struct _CPU_MP_DATA {
UINT64 CpuInfoInHob;
UINT32 CpuCount;
UINT32 BspNumber;
UINT64 MicrocodePatchAddress;
UINT64 MicrocodePatchRegionSize;
//
// The above fields data will be passed from PEI to DXE
// Please make sure the fields offset same in the different
@ -264,6 +262,8 @@ struct _CPU_MP_DATA {
UINT8 Vector;
BOOLEAN PeriodicMode;
BOOLEAN TimerInterruptState;
UINT64 MicrocodePatchAddress;
UINT64 MicrocodePatchRegionSize;
//
// Whether need to use Init-Sipi-Sipi to wake up the APs.