summaryrefslogtreecommitdiffstats
path: root/UefiCpuPkg/CpuDxe/X64
diff options
context:
space:
mode:
authorGuo Dong <guo.dong@intel.com>2020-12-02 14:18:18 -0700
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2020-12-08 22:17:55 +0000
commitcee5b0441af39dd6f76cc4e0447a1c7f788cbb00 (patch)
tree6d2110f2201a070cb463d7bbc398e42d9dbb9fcd /UefiCpuPkg/CpuDxe/X64
parent8e4cb8fbceb84b66b3b2fc45b9e93d70f732e970 (diff)
downloadedk2-cee5b0441af39dd6f76cc4e0447a1c7f788cbb00.tar.gz
edk2-cee5b0441af39dd6f76cc4e0447a1c7f788cbb00.tar.bz2
edk2-cee5b0441af39dd6f76cc4e0447a1c7f788cbb00.zip
UefiCpuPkg/CpuDxe: Fix boot error
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3084 When DXE drivers are dispatched above 4GB memory and the system is already in 64bit mode, the address setCodeSelectorLongJump in stack will be override by parameter. so change to use 64bit address and jump to qword address. Signed-off-by: Guo Dong <guo.dong@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com> Reviewed-by: Eric Dong <eric.dong@intel.com>
Diffstat (limited to 'UefiCpuPkg/CpuDxe/X64')
-rw-r--r--UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm4
1 files changed, 2 insertions, 2 deletions
diff --git a/UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm b/UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm
index c3489bcc3e..6ad32b49f4 100644
--- a/UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm
+++ b/UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm
@@ -23,8 +23,8 @@ ASM_PFX(SetCodeSelector):
sub rsp, 0x10
lea rax, [setCodeSelectorLongJump]
mov [rsp], rax
- mov [rsp+4], cx
- jmp dword far [rsp]
+ mov [rsp+8], cx
+ jmp qword far [rsp]
setCodeSelectorLongJump:
add rsp, 0x10
ret