summaryrefslogtreecommitdiff
path: root/arch/x86/boot/copy.S
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw2@infradead.org>2014-01-03 22:30:42 +0000
committerH. Peter Anvin <hpa@linux.intel.com>2014-01-04 13:59:06 -0800
commite24df921af484e9b7095ee06d236dabdb3bd9c1c (patch)
tree2e048a06af6025b66e862877fd456af94b5d9487 /arch/x86/boot/copy.S
parentdf90ca969035d3f6c95044e272f75bf417b14245 (diff)
x86, boot: Use .code16 instead of .code16gcc
This reverts commit 28b48688 ("x86, boot: use .code16gcc instead of .code16"). Versions of binutils older than 2.16 are already not working, so this workaround is no longer necessary either. At the same time, some of the transformations that .code16gcc does can be *extremely* counterintuitive to a human programmer. [ hpa: folded ret -> retl and call -> calll fixes from followup patch ] Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> Link: http://lkml.kernel.org/r/1388788242.2391.75.camel@shinybook.infradead.org Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'arch/x86/boot/copy.S')
-rw-r--r--arch/x86/boot/copy.S22
1 files changed, 11 insertions, 11 deletions
diff --git a/arch/x86/boot/copy.S b/arch/x86/boot/copy.S
index 11f272c6f5e9..1eb7d298b47d 100644
--- a/arch/x86/boot/copy.S
+++ b/arch/x86/boot/copy.S
@@ -14,7 +14,7 @@
* Memory copy routines
*/
- .code16gcc
+ .code16
.text
GLOBAL(memcpy)
@@ -30,7 +30,7 @@ GLOBAL(memcpy)
rep; movsb
popw %di
popw %si
- ret
+ retl
ENDPROC(memcpy)
GLOBAL(memset)
@@ -45,25 +45,25 @@ GLOBAL(memset)
andw $3, %cx
rep; stosb
popw %di
- ret
+ retl
ENDPROC(memset)
GLOBAL(copy_from_fs)
pushw %ds
pushw %fs
popw %ds
- call memcpy
+ calll memcpy
popw %ds
- ret
+ retl
ENDPROC(copy_from_fs)
GLOBAL(copy_to_fs)
pushw %es
pushw %fs
popw %es
- call memcpy
+ calll memcpy
popw %es
- ret
+ retl
ENDPROC(copy_to_fs)
#if 0 /* Not currently used, but can be enabled as needed */
@@ -71,17 +71,17 @@ GLOBAL(copy_from_gs)
pushw %ds
pushw %gs
popw %ds
- call memcpy
+ calll memcpy
popw %ds
- ret
+ retl
ENDPROC(copy_from_gs)
GLOBAL(copy_to_gs)
pushw %es
pushw %gs
popw %es
- call memcpy
+ calll memcpy
popw %es
- ret
+ retl
ENDPROC(copy_to_gs)
#endif