]> git.proxmox.com Git - mirror_edk2.git/blobdiff - UnixPkg/Sec/Ia32/Gasket.S
Fix reverse gasket issue that was breaking watch dog timer.
[mirror_edk2.git] / UnixPkg / Sec / Ia32 / Gasket.S
index 77e8296b0b63f721735c4cfbbaa6ec42255a830f..046409052788b917cb5314d9edb4c91a4ca8d26a 100644 (file)
@@ -16,8 +16,8 @@
 # on Leopard and _stat$INDOE64 on Snow Leopard. That is why we pass stat()\r
 # into one of these gaskets from C code.\r
 #\r
-# Copyright (c) 2008 - 2009 Apple Inc. All rights reserved.\r
-# All rights reserved. This program and the accompanying materials\r
+# Copyright (c) 2008 - 2010, Apple Inc. 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
 # http://opensource.org/licenses/bsd-license.php\r
@@ -27,6 +27,8 @@
 #\r
 #------------------------------------------------------------------------------\r
 \r
+#ifdef __APPLE__\r
+\r
   .text\r
 \r
 #------------------------------------------------------------------------------\r
@@ -233,5 +235,28 @@ _GasketUintnUint16:
   call  *%eax\r
   leave\r
   ret\r
-\r
+  \r
+  \r
+.globl _ReverseGasketUint64\r
+_ReverseGasketUint64:\r
+       pushl   %ebp\r
+       movl    %esp, %ebp\r
+       subl    $40, %esp\r
+       movl    12(%ebp), %eax\r
+       movl    %eax, -16(%ebp)\r
+       movl    16(%ebp), %eax\r
+       movl    %eax, -12(%ebp)\r
+       movl    -16(%ebp), %eax\r
+       movl    -12(%ebp), %edx\r
+       movl    %eax, (%esp)\r
+       movl    %edx, 4(%esp)\r
+       movl    8(%ebp), %eax\r
+       call    *%eax\r
+       leave\r
+       ret\r
+  \r
+  \r
   .subsections_via_symbols\r
+  \r
+  #endif\r
+  \r