The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
Ia32/hypercall.asm to Ia32/hypercall.nasm
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16314
6f19259b-4bc3-4df7-8a09-
765794883524
+++ /dev/null
-# INTN\r
-# EFIAPI\r
-# XenHypercall2 (\r
-# IN VOID *HypercallAddr,\r
-# IN OUT INTN Arg1,\r
-# IN OUT INTN Arg2\r
-# );\r
-ASM_GLOBAL ASM_PFX(XenHypercall2)\r
-ASM_PFX(XenHypercall2):\r
- # Save only ebx, ecx is supposed to be a scratch register and needs to be\r
- # saved by the caller\r
- push %ebx\r
- # Copy HypercallAddr to eax\r
- mov 8(%esp), %eax\r
- # Copy Arg1 to the register expected by Xen\r
- mov 12(%esp), %ebx\r
- # Copy Arg2 to the register expected by Xen\r
- mov 16(%esp), %ecx\r
- # Call HypercallAddr\r
- call *%eax\r
- pop %ebx\r
- ret\r
+++ /dev/null
-.code\r
-\r
-; INTN\r
-; EFIAPI\r
-; XenHypercall2 (\r
-; IN VOID *HypercallAddr,\r
-; IN OUT INTN Arg1,\r
-; IN OUT INTN Arg2\r
-; );\r
-XenHypercall2 PROC\r
- ; Save only ebx, ecx is supposed to be a scratch register and needs to be\r
- ; saved by the caller\r
- push ebx\r
- ; Copy HypercallAddr to eax\r
- mov eax, [esp + 8]\r
- ; Copy Arg1 to the register expected by Xen\r
- mov ebx, [esp + 12]\r
- ; Copy Arg2 to the register expected by Xen\r
- mov ecx, [esp + 16]\r
- ; Call HypercallAddr\r
- call eax\r
- pop ebx\r
- ret\r
-XenHypercall2 ENDP\r
-\r
-END\r
--- /dev/null
+SECTION .text\r
+\r
+; INTN\r
+; EFIAPI\r
+; XenHypercall2 (\r
+; IN VOID *HypercallAddr,\r
+; IN OUT INTN Arg1,\r
+; IN OUT INTN Arg2\r
+; );\r
+global ASM_PFX(XenHypercall2)\r
+ASM_PFX(XenHypercall2):\r
+ ; Save only ebx, ecx is supposed to be a scratch register and needs to be\r
+ ; saved by the caller\r
+ push ebx\r
+ ; Copy HypercallAddr to eax\r
+ mov eax, [esp + 8]\r
+ ; Copy Arg1 to the register expected by Xen\r
+ mov ebx, [esp + 12]\r
+ ; Copy Arg2 to the register expected by Xen\r
+ mov ecx, [esp + 16]\r
+ ; Call HypercallAddr\r
+ call eax\r
+ pop ebx\r
+ ret\r
+\r
Helpers.c\r
\r
[Sources.IA32]\r
- Ia32/hypercall.S\r
- Ia32/hypercall.asm\r
+ Ia32/hypercall.nasm\r
Ia32/InterlockedCompareExchange16.S\r
Ia32/InterlockedCompareExchange16.asm\r
Ia32/TestAndClearBit.S\r