]> git.proxmox.com Git - mirror_edk2.git/blob - OvmfPkg/XenBusDxe/Ia32/hypercall.asm
OvmfPkg/XenBusDxe: Introduce XenBus support itself.
[mirror_edk2.git] / OvmfPkg / XenBusDxe / Ia32 / hypercall.asm
1 .code
2
3 ; INTN
4 ; EFIAPI
5 ; XenHypercall2 (
6 ; IN VOID *HypercallAddr,
7 ; IN OUT INTN Arg1,
8 ; IN OUT INTN Arg2
9 ; );
10 XenHypercall2 PROC
11 ; Save only ebx, ecx is supposed to be a scratch register and needs to be
12 ; saved by the caller
13 push ebx
14 ; Copy HypercallAddr to eax
15 mov eax, [esp + 8]
16 ; Copy Arg1 to the register expected by Xen
17 mov ebx, [esp + 12]
18 ; Copy Arg2 to the register expected by Xen
19 mov ecx, [esp + 16]
20 ; Call HypercallAddr
21 call eax
22 pop ebx
23 ret
24 XenHypercall2 ENDP
25
26 END