summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorHeinrich Schuchardt <xypron.glpk@gmx.de>2020-03-22 11:52:48 +0300
committerHeinrich Schuchardt <xypron.glpk@gmx.de>2020-03-22 13:06:23 +0300
commit72291a9d83ec2fe50cc8fac304e8ecd5534daf5e (patch)
treebd4f1f90e48d52e087613176f79b2c943f0ce5c4 /lib
parent7aeceffb2509ba700673fa125bbfe785c4c0be71 (diff)
downloadu-boot-72291a9d83ec2fe50cc8fac304e8ecd5534daf5e.tar.xz
efi_loader: fix freestanding memmove()
For EFI binaries we have to provide an implementation of memmove() in efi_freestanding.c. Before this patch the memmove() function was copying in the wrong direction. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Diffstat (limited to 'lib')
-rw-r--r--lib/efi_loader/efi_freestanding.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/efi_loader/efi_freestanding.c b/lib/efi_loader/efi_freestanding.c
index dcf5d1c49a..bd0dff162f 100644
--- a/lib/efi_loader/efi_freestanding.c
+++ b/lib/efi_loader/efi_freestanding.c
@@ -47,7 +47,7 @@ void *memmove(void *dest, const void *src, size_t n)
u8 *d = dest;
const u8 *s = src;
- if (d >= s) {
+ if (d <= s) {
for (; n; --n)
*d++ = *s++;
} else {