summaryrefslogtreecommitdiff
path: root/UnixPkg/Sec/Ia32
diff options
context:
space:
mode:
authorandrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524>2010-08-08 19:07:14 +0000
committerandrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524>2010-08-08 19:07:14 +0000
commit2ec364f9bf0a66e56e752088aa3e7b124262d2a5 (patch)
treec3cb1bb973dc08b2682f19f57e80d5e699549b8c /UnixPkg/Sec/Ia32
parentd0d41b52e06296fc148470f18eb6aaddfef36bdc (diff)
downloadedk2-platforms-2ec364f9bf0a66e56e752088aa3e7b124262d2a5.tar.xz
Fix reverse gasket issue that was breaking watch dog timer.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10779 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'UnixPkg/Sec/Ia32')
-rw-r--r--UnixPkg/Sec/Ia32/Gasket.S16
-rw-r--r--UnixPkg/Sec/Ia32/GasketTemplate.c3
2 files changed, 12 insertions, 7 deletions
diff --git a/UnixPkg/Sec/Ia32/Gasket.S b/UnixPkg/Sec/Ia32/Gasket.S
index caeabf89eb..0464090527 100644
--- a/UnixPkg/Sec/Ia32/Gasket.S
+++ b/UnixPkg/Sec/Ia32/Gasket.S
@@ -235,23 +235,27 @@ _GasketUintnUint16:
call *%eax
leave
ret
+
+
.globl _ReverseGasketUint64
_ReverseGasketUint64:
pushl %ebp
movl %esp, %ebp
- subl $56, %esp
+ subl $40, %esp
movl 12(%ebp), %eax
- movl %eax, -32(%ebp)
+ movl %eax, -16(%ebp)
movl 16(%ebp), %eax
- movl %eax, -28(%ebp)
- movl 8(%ebp), %eax
movl %eax, -12(%ebp)
- movl -32(%ebp), %eax
+ movl -16(%ebp), %eax
+ movl -12(%ebp), %edx
movl %eax, (%esp)
- movl -12(%ebp), %eax
+ movl %edx, 4(%esp)
+ movl 8(%ebp), %eax
call *%eax
leave
ret
+
+
.subsections_via_symbols
#endif
diff --git a/UnixPkg/Sec/Ia32/GasketTemplate.c b/UnixPkg/Sec/Ia32/GasketTemplate.c
index 8ff801d72e..bb703bf631 100644
--- a/UnixPkg/Sec/Ia32/GasketTemplate.c
+++ b/UnixPkg/Sec/Ia32/GasketTemplate.c
@@ -35,6 +35,7 @@ typedef UINT32 UINTN;
typedef int (*GASKET_VOID) ();
typedef int (*GASKET_UINTN) (UINTN);
+typedef int (*GASKET_UINT64) (UINT64);
typedef int (*GASKET_UINTN_UINTN) (UINTN, UINTN);
typedef int (*GASKET_UINTN_UINTN_UINTN) (UINTN, UINTN, UINTN);
typedef int (*GASKET_UINTN_UINTN_UINTN_UINTN) (UINTN, UINTN, UINTN, UINTN);
@@ -143,7 +144,7 @@ ReverseGasketUint64 (void *api, UINT64 a)
{
GASKET_UINTN func;
- func = (GASKET_UINTN)api;
+ func = (GASKET_UINT64)api;
func (a);
return;
}