]> git.proxmox.com Git - mirror_edk2.git/blobdiff - UefiCpuPkg/CpuDxe/X64/CpuAsm.asm
Clear the direction flag in interrupt/exception handlers' assembly entry code before...
[mirror_edk2.git] / UefiCpuPkg / CpuDxe / X64 / CpuAsm.asm
index 79edb7b83e829422f4de838d5ece02e8aa4445f0..68fcd3f404657451a50caf5e0d5c99963a3e2867 100644 (file)
@@ -1,7 +1,7 @@
       TITLE   CpuAsm.asm: \r
 ;------------------------------------------------------------------------------\r
 ;*\r
-;*   Copyright (c) 2008 - 2010, Intel Corporation. All rights reserved.<BR>\r
+;*   Copyright (c) 2008 - 2011, Intel Corporation. All rights reserved.<BR>\r
 ;*   This program and the accompanying materials                          \r
 ;*   are licensed and made available under the terms and conditions of the BSD License         \r
 ;*   which accompanies this distribution.  The full text of the license may be found at        \r
@@ -223,6 +223,9 @@ NoErrorCode:
     mov rdi, rsp\r
     db 0fh, 0aeh, 07h ;fxsave [rdi]\r
 \r
+;; UEFI calling convention for x64 requires that Direction flag in EFLAGs is clear\r
+    cld\r
+\r
 ;; UINT32  ExceptionData;\r
     push    qword ptr [rbp + 16]\r
 \r