]> git.proxmox.com Git - mirror_edk2.git/commitdiff
InOsEmuPkg: Fix UINT64 bugs in IA-32 gasket.
authorandrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524>
Sun, 19 Jun 2011 02:58:32 +0000 (02:58 +0000)
committerandrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524>
Sun, 19 Jun 2011 02:58:32 +0000 (02:58 +0000)
At this point IA-32 emulator boots the shell with an X11 GOP window. Block IO seems to have an issue that needs to be debugged.

Signed-off-by: andrewfish
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11854 6f19259b-4bc3-4df7-8a09-765794883524

InOsEmuPkg/Unix/Sec/Gasket.h
InOsEmuPkg/Unix/Sec/Ia32/Gasket.S

index 0862b2c9ac55b30c04eebb90c47c591e2908cf7b..a9ecf8dfc8d6ae13d521403642a2ce111c5b0550 100644 (file)
@@ -108,8 +108,8 @@ VOID
 EFIAPI\r
 GasketSecSleep (\r
   IN  UINT64 Milliseconds\r
-\r
   );\r
+  \r
 VOID\r
 EFIAPI\r
 GasketSecCpuSleep (\r
index eb5142b0aeee69cba5df2f28635f189086dae0a3..d9ac12d7f07b8515771a32d1a63f35554ea53536 100644 (file)
@@ -112,12 +112,14 @@ ASM_GLOBAL ASM_PFX(GasketSecSetTimer)
 ASM_PFX(GasketSecSetTimer):
   pushl %ebp
   movl  %esp, %ebp
-  subl  $24, %esp      // sub extra 16 from the stack for alignment
+  subl  $40, %esp      // sub extra 16 from the stack for alignment
   and   $-16, %esp    // stack needs to end in 0xFFFFFFF0 before call
-  movl  12(%ebp), %eax
-  movl  %eax, 4(%esp)
-  movl  8(%ebp), %eax
-  movl  %eax, (%esp)
+  movl 16(%ebp), %eax
+       movl    %eax, 8(%esp)
+       movl    8(%ebp), %eax
+       movl    12(%ebp), %edx
+       movl    %edx, 4(%esp)
+       movl    %eax, (%esp)
 
   call  ASM_PFX(SecSetTimer)
   
@@ -182,8 +184,10 @@ ASM_PFX(GasketSecSleep):
   movl  %esp, %ebp
   subl  $24, %esp      // sub extra 16 from the stack for alignment
   and   $-16, %esp    // stack needs to end in 0xFFFFFFF0 before call
-  movl  8(%ebp), %eax
-  movl  %eax, (%esp)
+       movl    8(%ebp), %eax
+       movl    12(%ebp), %ecx
+       movl    %ecx, 4(%esp)
+       movl    %eax, (%esp)
 
   call  ASM_PFX(SecSleep)
   
@@ -784,11 +788,15 @@ ASM_GLOBAL ASM_PFX(GasketPosixFileOpen)
 ASM_PFX(GasketPosixFileOpen):
        pushl   %ebp
        movl    %esp, %ebp
-  subl  $40, %esp      // sub extra 16 from the stack for alignment
+  subl  $56, %esp      // sub extra 16 from the stack for alignment
   and   $-16, %esp    // stack needs to end in 0xFFFFFFF0 before call
-       movl    24(%ebp), %eax
-       movl    %eax, 16(%esp)
+       movl    28(%ebp), %eax
+       movl    32(%ebp), %ecx
+       movl    %ecx, 24(%esp)
+       movl    %eax, 20(%esp)
        movl    20(%ebp), %eax
+       movl    24(%ebp), %ecx
+       movl    %ecx, 16(%esp)
        movl    %eax, 12(%esp)
        movl    16(%ebp), %eax
        movl    %eax, 8(%esp)
@@ -875,12 +883,14 @@ ASM_GLOBAL ASM_PFX(GasketPosixFileSetPossition)
 ASM_PFX(GasketPosixFileSetPossition):
   pushl %ebp
   movl  %esp, %ebp
-  subl  $24, %esp      // sub extra 16 from the stack for alignment
+  subl  $40, %esp      // sub extra 16 from the stack for alignment
   and   $-16, %esp    // stack needs to end in 0xFFFFFFF0 before call
-  movl  12(%ebp), %eax
-  movl  %eax, 4(%esp)
-  movl  8(%ebp), %eax
-  movl  %eax, (%esp)
+       movl    12(%ebp), %eax
+       movl    16(%ebp), %ecx
+       movl    %ecx, 8(%esp)
+       movl    %eax, 4(%esp)
+       movl    8(%ebp), %eax
+       movl    %eax, (%esp)
 
   call    ASM_PFX(PosixFileSetPossition)