From 6f6c3a1fb628be2b8fb68add9f166d8fa51a9c70 Mon Sep 17 00:00:00 2001 From: Anthony PERARD Date: Sat, 8 Nov 2014 02:41:35 +0000 Subject: OvmfPkg XenBusDxe: Convert X64/TestAndClearBit.asm to NASM The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert X64/TestAndClearBit.asm to X64/TestAndClearBit.nasm Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Anthony PERARD Reviewed-by: Jordan Justen git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16319 6f19259b-4bc3-4df7-8a09-765794883524 --- OvmfPkg/XenBusDxe/X64/TestAndClearBit.S | 12 ------------ OvmfPkg/XenBusDxe/X64/TestAndClearBit.asm | 16 ---------------- OvmfPkg/XenBusDxe/X64/TestAndClearBit.nasm | 16 ++++++++++++++++ OvmfPkg/XenBusDxe/XenBusDxe.inf | 3 +-- 4 files changed, 17 insertions(+), 30 deletions(-) delete mode 100644 OvmfPkg/XenBusDxe/X64/TestAndClearBit.S delete mode 100644 OvmfPkg/XenBusDxe/X64/TestAndClearBit.asm create mode 100644 OvmfPkg/XenBusDxe/X64/TestAndClearBit.nasm (limited to 'OvmfPkg') diff --git a/OvmfPkg/XenBusDxe/X64/TestAndClearBit.S b/OvmfPkg/XenBusDxe/X64/TestAndClearBit.S deleted file mode 100644 index 0372e83bdd..0000000000 --- a/OvmfPkg/XenBusDxe/X64/TestAndClearBit.S +++ /dev/null @@ -1,12 +0,0 @@ -# INT32 -# EFIAPI -# TestAndClearBit ( -# IN INT32 Bit, // rcx -# IN volatile VOID* Address // rdx -# ); -ASM_GLOBAL ASM_PFX(TestAndClearBit) -ASM_PFX(TestAndClearBit): - lock - btrl %ecx, (%rdx) - sbbl %eax, %eax - ret diff --git a/OvmfPkg/XenBusDxe/X64/TestAndClearBit.asm b/OvmfPkg/XenBusDxe/X64/TestAndClearBit.asm deleted file mode 100644 index 3a2587913e..0000000000 --- a/OvmfPkg/XenBusDxe/X64/TestAndClearBit.asm +++ /dev/null @@ -1,16 +0,0 @@ -.code - -; INT32 -; EFIAPI -; TestAndClearBit ( -; IN INT32 Bit, // rcx -; IN volatile VOID* Address // rdx -; ); -TestAndClearBit PROC - lock - btr [rdx], ecx - sbb eax, eax - ret -TestAndClearBit ENDP - -END diff --git a/OvmfPkg/XenBusDxe/X64/TestAndClearBit.nasm b/OvmfPkg/XenBusDxe/X64/TestAndClearBit.nasm new file mode 100644 index 0000000000..38ac5490cb --- /dev/null +++ b/OvmfPkg/XenBusDxe/X64/TestAndClearBit.nasm @@ -0,0 +1,16 @@ +DEFAULT REL +SECTION .text + +; INT32 +; EFIAPI +; TestAndClearBit ( +; IN INT32 Bit, // rcx +; IN volatile VOID* Address // rdx +; ); +global ASM_PFX(TestAndClearBit) +ASM_PFX(TestAndClearBit): + lock + btr [rdx], ecx + sbb eax, eax + ret + diff --git a/OvmfPkg/XenBusDxe/XenBusDxe.inf b/OvmfPkg/XenBusDxe/XenBusDxe.inf index 61f7568e55..4ce4743454 100644 --- a/OvmfPkg/XenBusDxe/XenBusDxe.inf +++ b/OvmfPkg/XenBusDxe/XenBusDxe.inf @@ -56,8 +56,7 @@ [Sources.X64] X64/hypercall.nasm X64/InterlockedCompareExchange16.nasm - X64/TestAndClearBit.S - X64/TestAndClearBit.asm + X64/TestAndClearBit.nasm [LibraryClasses] UefiDriverEntryPoint -- cgit v1.2.3