All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 3/4] sparc32: return destination pointer on return from memcpy
@ 2011-10-13  7:00 Konrad Eisele
  2011-10-19  4:07 ` [PATCH 3/4] sparc32: return destination pointer on return from David Miller
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: Konrad Eisele @ 2011-10-13  7:00 UTC (permalink / raw)
  To: sparclinux

Gcc can optimize constant strcpy to a memcpy call. However
the return value of strcpy is used in KGDB. Return the standard return
value instead of 0

Signed-off-by: Konrad Eisele <konrad@gaisler.com>
---
 arch/sparc/lib/memcpy.S |    8 ++------
 1 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/arch/sparc/lib/memcpy.S b/arch/sparc/lib/memcpy.S
index 34fe657..835014b 100644
--- a/arch/sparc/lib/memcpy.S
+++ b/arch/sparc/lib/memcpy.S
@@ -19,12 +19,8 @@ x:
 #undef FASTER_NONALIGNED
 #define FASTER_ALIGNED
 
-/* In kernel these functions don't return a value.
- * One should use macros in asm/string.h for that purpose.
- * We return 0, so that bugs are more apparent.
- */
-#define SETUP_RETL
-#define RETL_INSN	clr	%o0
+#define SETUP_RETL	mov	%o0, %g6
+#define RETL_INSN	mov	%g6, %o0
 
 #else
 
-- 
1.6.4.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2011-10-20  9:08 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-13  7:00 [PATCH 3/4] sparc32: return destination pointer on return from memcpy Konrad Eisele
2011-10-19  4:07 ` [PATCH 3/4] sparc32: return destination pointer on return from David Miller
2011-10-19  8:33 ` Konrad Eisele
2011-10-19 19:29 ` David Miller
2011-10-19 21:11 ` Kjetil Oftedal
2011-10-19 22:12 ` David Miller
2011-10-20  6:59 ` Konrad Eisele
2011-10-20  8:47 ` David Miller
2011-10-20  9:08 ` Konrad Eisele

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.