From ea926532c3cc9ecc6c2379b7505ce3a840d909a1 Mon Sep 17 00:00:00 2001 From: Douglas Raillard <douglas.raillard@arm.com> Date: Fri, 2 Dec 2016 13:56:06 +0000 Subject: [PATCH] Fix integer comparison in memcpy16 Unsigned conditions should be used instead of signed ones when comparing addresses or sizes in assembly. Signed-off-by: Douglas Raillard <douglas.raillard@arm.com> Change-Id: Id3bd9ccaf58c37037761af35ac600907c4bb0580 --- lib/aarch64/misc_helpers.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/aarch64/misc_helpers.S b/lib/aarch64/misc_helpers.S index e7c246ea2..574146f6d 100644 --- a/lib/aarch64/misc_helpers.S +++ b/lib/aarch64/misc_helpers.S @@ -123,7 +123,7 @@ func memcpy16 /* copy 16 bytes at a time */ m_loop16: cmp x2, #16 - b.lt m_loop1 + b.lo m_loop1 ldp x3, x4, [x1], #16 stp x3, x4, [x0], #16 sub x2, x2, #16 -- GitLab