From 423c01eac31fe9e6c9eee7bf45ace9abcd57251b Mon Sep 17 00:00:00 2001 From: Greg Ungerer Date: Mon, 29 Oct 2012 16:15:43 +1000 Subject: m68k: fix unused variable warning in mempcy.c MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When compiling for original 68000 or ColdFire targets you will get the following warning when compiling arch/m68k/lib/memcpy.c: CC arch/m68k/lib/memcpy.o arch/m68k/lib/memcpy.c: In function ‘__builtin_memcpy’: arch/m68k/lib/memcpy.c:13:15: warning: unused variable ‘temp1’ This is easily fixed by moving the definition of temp1 into the code block where it is used. Signed-off-by: Greg Ungerer --- arch/m68k/lib/memcpy.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'arch/m68k/lib') diff --git a/arch/m68k/lib/memcpy.c b/arch/m68k/lib/memcpy.c index 10ca051d56b8..c1e2dfb206f3 100644 --- a/arch/m68k/lib/memcpy.c +++ b/arch/m68k/lib/memcpy.c @@ -10,7 +10,7 @@ void *memcpy(void *to, const void *from, size_t n) { void *xto = to; - size_t temp, temp1; + size_t temp; if (!n) return xto; @@ -47,6 +47,7 @@ void *memcpy(void *to, const void *from, size_t n) for (; temp; temp--) *lto++ = *lfrom++; #else + size_t temp1; asm volatile ( " movel %2,%3\n" " andw #7,%3\n" -- cgit v1.2.3