summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--MdePkg/Library/BaseLib/X64/CpuIdEx.S4
-rw-r--r--MdePkg/Library/BaseLib/X64/DisablePaging64.S19
-rw-r--r--MdePkg/Library/BaseLib/X64/FlushCacheLine.S6
-rw-r--r--MdePkg/Library/BaseLib/X64/InterlockedCompareExchange32.S4
-rw-r--r--MdePkg/Library/BaseLib/X64/InterlockedCompareExchange64.S6
-rw-r--r--MdePkg/Library/BaseLib/X64/LongJump.S2
-rw-r--r--MdePkg/Library/BaseLib/X64/WriteMm0.S4
7 files changed, 22 insertions, 23 deletions
diff --git a/MdePkg/Library/BaseLib/X64/CpuIdEx.S b/MdePkg/Library/BaseLib/X64/CpuIdEx.S
index d7154eb4fc..62d698a584 100644
--- a/MdePkg/Library/BaseLib/X64/CpuIdEx.S
+++ b/MdePkg/Library/BaseLib/X64/CpuIdEx.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006, Intel Corporation
+# Copyright (c) 2006 - 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -11,7 +11,7 @@
#
# Module Name:
#
-# CpuIdEx.Asm
+# CpuIdEx.S
#
# Abstract:
#
diff --git a/MdePkg/Library/BaseLib/X64/DisablePaging64.S b/MdePkg/Library/BaseLib/X64/DisablePaging64.S
index 4ca4145fa2..7a543febab 100644
--- a/MdePkg/Library/BaseLib/X64/DisablePaging64.S
+++ b/MdePkg/Library/BaseLib/X64/DisablePaging64.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006, Intel Corporation
+# Copyright (c) 2006 - 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -39,14 +39,13 @@
ASM_PFX(InternalX86DisablePaging64):
cli
shl $0x20,%rcx
- lea (%rip), %eax
- mov %eax,%ecx
- push %rcx
- mov %edx,%ebx
- mov %r8d,%esi
- mov %r9d,%edi
- mov 0x28(%rsp),%eax
- lret
+ lea L1, %eax
+ mov %r8d, %esi
+ or %rax, %rcx
+ mov %r9d, %edi
+ mov 0x28(%rsp), %eax
+ push %rcx
+ ret
L1:
mov %eax,%esp
mov %cr0,%rax
@@ -61,6 +60,6 @@ L1:
mov %rax,%cr4
push %rdi
push %rsi
- callq *%rbx
+ callq *%rdx
jmp .
diff --git a/MdePkg/Library/BaseLib/X64/FlushCacheLine.S b/MdePkg/Library/BaseLib/X64/FlushCacheLine.S
index 0d05d41f65..fa6cfb2e67 100644
--- a/MdePkg/Library/BaseLib/X64/FlushCacheLine.S
+++ b/MdePkg/Library/BaseLib/X64/FlushCacheLine.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006, Intel Corporation
+# Copyright (c) 2006 - 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -31,6 +31,6 @@
#------------------------------------------------------------------------------
.global ASM_PFX(AsmFlushCacheLine)
ASM_PFX(AsmFlushCacheLine):
- clflush (%rdi)
- mov %rdi, %rax
+ clflush (%rcx)
+ mov %rcx, %rax
ret
diff --git a/MdePkg/Library/BaseLib/X64/InterlockedCompareExchange32.S b/MdePkg/Library/BaseLib/X64/InterlockedCompareExchange32.S
index d248a10369..8faca8b7b1 100644
--- a/MdePkg/Library/BaseLib/X64/InterlockedCompareExchange32.S
+++ b/MdePkg/Library/BaseLib/X64/InterlockedCompareExchange32.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006, Intel Corporation
+# Copyright (c) 2006 - 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -11,7 +11,7 @@
#
# Module Name:
#
-# InterlockedCompareExchange32.Asm
+# InterlockedCompareExchange32.S
#
# Abstract:
#
diff --git a/MdePkg/Library/BaseLib/X64/InterlockedCompareExchange64.S b/MdePkg/Library/BaseLib/X64/InterlockedCompareExchange64.S
index 95f9d0501b..2034b670f1 100644
--- a/MdePkg/Library/BaseLib/X64/InterlockedCompareExchange64.S
+++ b/MdePkg/Library/BaseLib/X64/InterlockedCompareExchange64.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006, Intel Corporation
+# Copyright (c) 2006 - 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -34,6 +34,6 @@
.global ASM_PFX(InternalSyncCompareExchange64)
.align 16
ASM_PFX(InternalSyncCompareExchange64):
- mov %rsi, %rax
- lock cmpxchg %rdx,(%rdi)
+ mov %rdx, %rax
+ lock cmpxchg %r8,(%rcx)
ret
diff --git a/MdePkg/Library/BaseLib/X64/LongJump.S b/MdePkg/Library/BaseLib/X64/LongJump.S
index 1d6a916e04..69229c2bf1 100644
--- a/MdePkg/Library/BaseLib/X64/LongJump.S
+++ b/MdePkg/Library/BaseLib/X64/LongJump.S
@@ -11,7 +11,7 @@
#
# Module Name:
#
-# LongJump.Asm
+# LongJump.S
#
# Abstract:
#
diff --git a/MdePkg/Library/BaseLib/X64/WriteMm0.S b/MdePkg/Library/BaseLib/X64/WriteMm0.S
index 03b0ae09c6..40e0a56dc3 100644
--- a/MdePkg/Library/BaseLib/X64/WriteMm0.S
+++ b/MdePkg/Library/BaseLib/X64/WriteMm0.S
@@ -1,6 +1,6 @@
#------------------------------------------------------------------------------
#
-# Copyright (c) 2006, Intel Corporation
+# Copyright (c) 2006 - 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
@@ -31,5 +31,5 @@
#------------------------------------------------------------------------------
.global ASM_PFX(AsmWriteMm0)
ASM_PFX(AsmWriteMm0):
- movd %rcx, %xmm0
+ movd %rcx, %mm0
ret