summaryrefslogtreecommitdiffstats
path: root/arch/arm/lib
diff options
context:
space:
mode:
authorMatthias Weisser <weisserm@arcor.de>2011-05-22 23:06:50 +0000
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2011-09-03 22:40:45 +0200
commit34fe8281d7323784544e94d2f7218f52b8a2899d (patch)
tree93a4c71a8f0d447dff324a79b7221f1f47707e6a /arch/arm/lib
parent2141e14428924792d5d0f1770d7c03bdc892208c (diff)
downloadblackbird-obmc-uboot-34fe8281d7323784544e94d2f7218f52b8a2899d.tar.gz
blackbird-obmc-uboot-34fe8281d7323784544e94d2f7218f52b8a2899d.zip
arm: lib: memcpy: Do not copy to same address
In some cases (e.g. bootm with a elf payload which is already at the right position) there is a in place copy of data to the same address. Catching this saves some ms while booting. Signed-off-by: Matthias Weisser <weisserm@arcor.de>
Diffstat (limited to 'arch/arm/lib')
-rw-r--r--arch/arm/lib/memcpy.S3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/arm/lib/memcpy.S b/arch/arm/lib/memcpy.S
index 3b5aeec4cf..f655256b5d 100644
--- a/arch/arm/lib/memcpy.S
+++ b/arch/arm/lib/memcpy.S
@@ -60,6 +60,9 @@
.globl memcpy
memcpy:
+ cmp r0, r1
+ moveq pc, lr
+
enter r4, lr
subs r2, r2, #4
OpenPOWER on IntegriCloud