diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2015-01-29 06:36:53 -0600 |
---|---|---|
committer | Lorenz Meier <lm@inf.ethz.ch> | 2015-01-29 16:28:04 +0100 |
commit | 37cbc3e8ae6b75e9b7e79996d30fe8ed0beb9704 (patch) | |
tree | cb70f7448f2224eb58e1d325d9b34f01b00136de | |
parent | 5a028df57aba8fe530a6f7c8341ae1c6208c575c (diff) | |
download | nuttx-37cbc3e8ae6b75e9b7e79996d30fe8ed0beb9704.tar.gz nuttx-37cbc3e8ae6b75e9b7e79996d30fe8ed0beb9704.tar.bz2 nuttx-37cbc3e8ae6b75e9b7e79996d30fe8ed0beb9704.zip |
Backport memcpy fix
-rw-r--r-- | nuttx/arch/arm/src/armv7-m/up_memcpy.S | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/nuttx/arch/arm/src/armv7-m/up_memcpy.S b/nuttx/arch/arm/src/armv7-m/up_memcpy.S index ea267f78f..84877b040 100644 --- a/nuttx/arch/arm/src/armv7-m/up_memcpy.S +++ b/nuttx/arch/arm/src/armv7-m/up_memcpy.S @@ -142,11 +142,26 @@ MEM_LongCopyTable: * Input Parameters: * r0 = destination, r1 = source, r2 = length * + * Returned Value: + * r0 = destination r1-r3 burned + * ************************************************************************************/ + .align 4 .thumb_func + memcpy: push {r14} + push {r0} + bl _do_memcpy + pop {r0} + pop {pc} + + .align 4 + + .thumb_func +_do_memcpy: + push {r14} /* This allows the inner workings to "assume" a minimum amount of bytes */ /* Quickly check for very short copies */ |