]> git.proxmox.com Git - mirror_edk2.git/commit
UefiCpuPkg PiSmmCpuDxeSmm: Update X64/MpFuncs.nasm
authorLiming Gao <liming.gao@intel.com>
Tue, 14 Jun 2016 08:35:08 +0000 (16:35 +0800)
committerLiming Gao <liming.gao@intel.com>
Tue, 28 Jun 2016 01:52:16 +0000 (09:52 +0800)
commite1f0eed1b2a9954428708bd91243f981e3161301
treea01354cdaaeb532c2b6969a3a6614b3d245737cb
parent78cf66eebbdbc4e6b068923185d6c61c549a7279
UefiCpuPkg PiSmmCpuDxeSmm: Update X64/MpFuncs.nasm

Use 16bit and 32bit assembly code to replace hard code db.

In V2: add 0x67 prefixes to far jumps

Without the a32 modifier under FLAT32_JUMP, and the a16 modifier under
LONG_JUMP, nasm doesn't generate the 0x67 prefixes, and the far jumps
don't work. (For the former, KVM returns an emulation failure. For the
latter, KVM performs a triple fault (guest reboot).) By forcing the 0x67
prefixes we end up with the same machine code as the one open-coded in
"MpFuncs.asm".

This bug breaks S3 resume in the Ia32X64 + SMM_REQUIRE build of OVMF.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Liming Gao <liming.gao@intel.com>
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
UefiCpuPkg/PiSmmCpuDxeSmm/X64/MpFuncs.nasm