Patchwork [3.5.y.z,extended,stable] Patch "x86, efi: Fix processor-specific memcpy() build error" has been added to staging queue

mail settings
Submitter Herton Ronaldo Krzesinski
Date Dec. 10, 2012, 2:19 p.m.
Message ID <>
Download mbox | patch
Permalink /patch/204909/
State New
Headers show


Herton Ronaldo Krzesinski - Dec. 10, 2012, 2:19 p.m.
This is a note to let you know that I have just added a patch titled

    x86, efi: Fix processor-specific memcpy() build error

to the linux-3.5.y-queue branch of the 3.5.y.z extended stable tree 
which can be found at:;a=shortlog;h=refs/heads/linux-3.5.y-queue

If you, or anyone else, feels it should not be added to this tree, please 
reply to this email.

For more information about the 3.5.y.z tree, see



From 20720cc36b81e368b781394bf8dc06c572f19803 Mon Sep 17 00:00:00 2001
From: Matt Fleming <>
Date: Tue, 20 Nov 2012 13:07:46 +0000
Subject: [PATCH] x86, efi: Fix processor-specific memcpy() build error

commit 0f905a43ce955b638139bd84486194770a6a2c08 upstream.

Building for Athlon/Duron/K7 results in the following build error,

arch/x86/boot/compressed/eboot.o: In function `__constant_memcpy3d':
eboot.c:(.text+0x385): undefined reference to `_mmx_memcpy'
arch/x86/boot/compressed/eboot.o: In function `efi_main':
eboot.c:(.text+0x1a22): undefined reference to `_mmx_memcpy'

because the boot stub code doesn't link with the kernel proper, and
therefore doesn't have access to the 3DNow version of memcpy. So,
follow the example of misc.c and #undef memcpy so that we use the
version provided by misc.c.


Reported-by: Al Viro <>
Reported-by: Ryan Underwood <>
Cc: H. Peter Anvin <>
Signed-off-by: Matt Fleming <>
Signed-off-by: Herton Ronaldo Krzesinski <>
 arch/x86/boot/compressed/eboot.c |    2 ++
 1 file changed, 2 insertions(+)



diff --git a/arch/x86/boot/compressed/eboot.c b/arch/x86/boot/compressed/eboot.c
index 4e85f5f..f204178 100644
--- a/arch/x86/boot/compressed/eboot.c
+++ b/arch/x86/boot/compressed/eboot.c
@@ -12,6 +12,8 @@ 
 #include <asm/setup.h>
 #include <asm/desc.h>

+#undef memcpy			/* Use memcpy from misc.c */
 #include "eboot.h"

 static efi_system_table_t *sys_table;