diff options
author | Jian J Wang <jian.j.wang@intel.com> | 2018-01-04 10:57:26 +0800 |
---|---|---|
committer | Star Zeng <star.zeng@intel.com> | 2018-01-12 18:19:12 +0800 |
commit | afa9d3959d7d46069b5a7ee61ca5dc4b23fe9fda (patch) | |
tree | d7c15f20a325396134f7bd4ffd1a700722e1428b /UefiCpuPkg | |
parent | c41d8c62f283c109f55d503a1b2e800bb3951c05 (diff) | |
download | edk2-afa9d3959d7d46069b5a7ee61ca5dc4b23fe9fda.tar.gz edk2-afa9d3959d7d46069b5a7ee61ca5dc4b23fe9fda.tar.bz2 edk2-afa9d3959d7d46069b5a7ee61ca5dc4b23fe9fda.zip |
UefiCpuPkg/MpInitLib: fix incorrect stack top init for cpu0
As the name suggests, CpuMpData->CpuInfoInHob[0].ApTopOfStack must be init
to the top of stack. But the MpInitLibInitialize() passed the base address
of stack to InitializeApData(), which is not correct. Although this stack
is not used for BSP, it's should be fixed in case of misunderstanding and
future possible code changes.
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Jian J Wang <jian.j.wang@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>
(cherry picked from commit f2655dcf28c4dbece5bdf6433a2624e68ea7aeb4)
Diffstat (limited to 'UefiCpuPkg')
-rw-r--r-- | UefiCpuPkg/Library/MpInitLib/MpLib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/UefiCpuPkg/Library/MpInitLib/MpLib.c b/UefiCpuPkg/Library/MpInitLib/MpLib.c index 1a6cdb678e..cdc03113e5 100644 --- a/UefiCpuPkg/Library/MpInitLib/MpLib.c +++ b/UefiCpuPkg/Library/MpInitLib/MpLib.c @@ -1502,7 +1502,7 @@ MpInitLibInitialize ( //
// Set BSP basic information
//
- InitializeApData (CpuMpData, 0, 0, CpuMpData->Buffer);
+ InitializeApData (CpuMpData, 0, 0, CpuMpData->Buffer + ApStackSize);
//
// Save assembly code information
//
|