OvmfPkg PciHostBridgeDxe: Convert Ia32/IoFifo.asm to NASM

The BaseTools/Scripts/ConvertMasmToNasm.py script was used to convert
Ia32/IoFifo.asm to Ia32/IoFifo.nasm

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
This commit is contained in:
Jordan Justen 2016-03-07 19:18:03 -08:00 committed by Laszlo Ersek
parent 43ca17532b
commit 6026bf4600
3 changed files with 14 additions and 153 deletions

View File

@ -1,134 +0,0 @@
#------------------------------------------------------------------------------
#
# Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
#
# 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
# http://opensource.org/licenses/bsd-license.php.
#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
#------------------------------------------------------------------------------
#------------------------------------------------------------------------------
# VOID
# EFIAPI
# IoReadFifo8 (
# IN UINTN Port,
# IN UINTN Count,
# IN VOID *Buffer
# );
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(IoReadFifo8)
ASM_PFX(IoReadFifo8):
push %edi
cld
movw 8(%esp), %dx
mov 12(%esp), %ecx
mov 16(%esp), %edi
rep insb
pop %edi
ret
#------------------------------------------------------------------------------
# VOID
# EFIAPI
# IoReadFifo16 (
# IN UINTN Port,
# IN UINTN Count,
# IN VOID *Buffer
# );
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(IoReadFifo16)
ASM_PFX(IoReadFifo16):
push %edi
cld
movw 8(%esp), %dx
mov 12(%esp), %ecx
mov 16(%esp), %edi
rep insw
pop %edi
ret
#------------------------------------------------------------------------------
# VOID
# EFIAPI
# IoReadFifo32 (
# IN UINTN Port,
# IN UINTN Count,
# IN VOID *Buffer
# );
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(IoReadFifo32)
ASM_PFX(IoReadFifo32):
push %edi
cld
movw 8(%esp), %dx
mov 12(%esp), %ecx
mov 16(%esp), %edi
rep insl
pop %edi
ret
#------------------------------------------------------------------------------
# VOID
# EFIAPI
# IoWriteFifo8 (
# IN UINTN Port,
# IN UINTN Count,
# IN VOID *Buffer
# );
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(IoWriteFifo8)
ASM_PFX(IoWriteFifo8):
push %esi
cld
movw 8(%esp), %dx
mov 12(%esp), %ecx
mov 16(%esp), %esi
rep outsb
pop %esi
ret
#------------------------------------------------------------------------------
# VOID
# EFIAPI
# IoWriteFifo16 (
# IN UINTN Port,
# IN UINTN Count,
# IN VOID *Buffer
# );
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(IoWriteFifo16)
ASM_PFX(IoWriteFifo16):
push %esi
cld
movw 8(%esp), %dx
mov 12(%esp), %ecx
mov 16(%esp), %esi
rep outsw
pop %esi
ret
#------------------------------------------------------------------------------
# VOID
# EFIAPI
# IoWriteFifo32 (
# IN UINTN Port,
# IN UINTN Count,
# IN VOID *Buffer
# );
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(IoWriteFifo32)
ASM_PFX(IoWriteFifo32):
push %esi
cld
movw 8(%esp), %dx
mov 12(%esp), %ecx
mov 16(%esp), %esi
rep outsl
pop %esi
ret

View File

@ -12,9 +12,7 @@
; ;
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
.586P SECTION .text
.model flat,C
.code
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
; VOID ; VOID
@ -25,7 +23,8 @@
; IN VOID *Buffer ; IN VOID *Buffer
; ); ; );
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
IoReadFifo8 PROC global ASM_PFX(IoReadFifo8)
ASM_PFX(IoReadFifo8):
push edi push edi
cld cld
mov dx, [esp + 8] mov dx, [esp + 8]
@ -34,7 +33,6 @@ IoReadFifo8 PROC
rep insb rep insb
pop edi pop edi
ret ret
IoReadFifo8 ENDP
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
; VOID ; VOID
@ -45,7 +43,8 @@ IoReadFifo8 ENDP
; IN VOID *Buffer ; IN VOID *Buffer
; ); ; );
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
IoReadFifo16 PROC global ASM_PFX(IoReadFifo16)
ASM_PFX(IoReadFifo16):
push edi push edi
cld cld
mov dx, [esp + 8] mov dx, [esp + 8]
@ -54,7 +53,6 @@ IoReadFifo16 PROC
rep insw rep insw
pop edi pop edi
ret ret
IoReadFifo16 ENDP
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
; VOID ; VOID
@ -65,7 +63,8 @@ IoReadFifo16 ENDP
; IN VOID *Buffer ; IN VOID *Buffer
; ); ; );
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
IoReadFifo32 PROC global ASM_PFX(IoReadFifo32)
ASM_PFX(IoReadFifo32):
push edi push edi
cld cld
mov dx, [esp + 8] mov dx, [esp + 8]
@ -74,7 +73,6 @@ IoReadFifo32 PROC
rep insd rep insd
pop edi pop edi
ret ret
IoReadFifo32 ENDP
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
; VOID ; VOID
@ -85,7 +83,8 @@ IoReadFifo32 ENDP
; IN VOID *Buffer ; IN VOID *Buffer
; ); ; );
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
IoWriteFifo8 PROC global ASM_PFX(IoWriteFifo8)
ASM_PFX(IoWriteFifo8):
push esi push esi
cld cld
mov dx, [esp + 8] mov dx, [esp + 8]
@ -94,7 +93,6 @@ IoWriteFifo8 PROC
rep outsb rep outsb
pop esi pop esi
ret ret
IoWriteFifo8 ENDP
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
; VOID ; VOID
@ -105,7 +103,8 @@ IoWriteFifo8 ENDP
; IN VOID *Buffer ; IN VOID *Buffer
; ); ; );
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
IoWriteFifo16 PROC global ASM_PFX(IoWriteFifo16)
ASM_PFX(IoWriteFifo16):
push esi push esi
cld cld
mov dx, [esp + 8] mov dx, [esp + 8]
@ -114,7 +113,6 @@ IoWriteFifo16 PROC
rep outsw rep outsw
pop esi pop esi
ret ret
IoWriteFifo16 ENDP
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
; VOID ; VOID
@ -125,7 +123,8 @@ IoWriteFifo16 ENDP
; IN VOID *Buffer ; IN VOID *Buffer
; ); ; );
;------------------------------------------------------------------------------ ;------------------------------------------------------------------------------
IoWriteFifo32 PROC global ASM_PFX(IoWriteFifo32)
ASM_PFX(IoWriteFifo32):
push esi push esi
cld cld
mov dx, [esp + 8] mov dx, [esp + 8]
@ -134,7 +133,4 @@ IoWriteFifo32 PROC
rep outsd rep outsd
pop esi pop esi
ret ret
IoWriteFifo32 ENDP
END

View File

@ -49,8 +49,7 @@
IoFifo.h IoFifo.h
[Sources.IA32] [Sources.IA32]
Ia32/IoFifo.asm Ia32/IoFifo.nasm
Ia32/IoFifo.S
[Sources.X64] [Sources.X64]
X64/IoFifo.asm X64/IoFifo.asm