]> git.proxmox.com Git - mirror_edk2.git/blob - OvmfPkg/Library/QemuFwCfgLib/X64/IoLibExAsm.asm
OvmfPkg: Add QemuFwCfgLib library class and implementation
[mirror_edk2.git] / OvmfPkg / Library / QemuFwCfgLib / X64 / IoLibExAsm.asm
1 ;------------------------------------------------------------------------------
2 ;
3 ; Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
4 ; This program and the accompanying materials
5 ; are licensed and made available under the terms and conditions of the BSD License
6 ; which accompanies this distribution. The full text of the license may be found at
7 ; http://opensource.org/licenses/bsd-license.php.
8 ;
9 ; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 ; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11 ;
12 ;------------------------------------------------------------------------------
13
14 .code
15
16 ;------------------------------------------------------------------------------
17 ; VOID
18 ; EFIAPI
19 ; IoReadFifo8 (
20 ; IN UINTN Port, // rcx
21 ; IN UINTN Size, // rdx
22 ; IN VOID *Buffer // r8
23 ; );
24 ;------------------------------------------------------------------------------
25 IoReadFifo8 PROC
26
27 xchg rcx, rdx
28 xchg rdi, r8 ; rdi: buffer address; r8: save rdi
29 rep insb
30 mov rdi, r8 ; restore rdi
31 ret
32
33 IoReadFifo8 ENDP
34
35 END
36