Bug #1628: Convert xf86{BusToMem,MemToBus} to PIC code, eliminating a text

relocation and enabling the server to be built as a
    position-independent executable. (PaX Team)
This commit is contained in:
Adam Jackson 2004-10-14 23:10:30 +00:00
parent a0251ee285
commit 881b5756dc

View File

@ -1,4 +1,4 @@
/* $XFree86: xc/programs/Xserver/hw/xfree86/os-support/misc/BUSmemcpy.S,v 1.1 1999/07/10 07:24:49 dawes Exp $ */
/* $XFree86: xc/programs/Xserver/hw/xfree86/os-support/misc/BUSmemcpy.s,v 1.2 1998/07/25 16:56:49 dawes Exp $ */
/******************************************************************************
Copyright 1993 by Glenn G. Lai
@ -61,14 +61,11 @@ Austin, Tx 78765
copyright:
STRING("Copyright 8/9/1993 by Glenn G. Lai")
ALIGNDATA4
tmp: D_LONG 0
SEG_TEXT
ALIGNTEXT4
GLNAME(xf86BusToMem):
CLD
MOV_L (ESI, CONTENT(tmp))
PUSH_L (ESI)
MOV_L (EDI, EDX)
MOV_L (src, ESI)
@ -105,7 +102,7 @@ quickBM:
REP
MOVS_B
return:
MOV_L (CONTENT(tmp), ESI)
POP_L (ESI)
MOV_L (EDX, EDI)
RET
/************************/
@ -113,7 +110,7 @@ return:
ALIGNTEXT4
GLNAME(xf86MemToBus):
CLD
MOV_L (ESI, CONTENT(tmp))
PUSH_L (ESI)
MOV_L (EDI, EDX)
MOV_L (src, ESI)
@ -150,7 +147,7 @@ quickMB:
REP
MOVS_B
MOV_L (CONTENT(tmp), ESI)
POP_L (ESI)
MOV_L (EDX, EDI)
RET