[PATCH] powerpc: Fix __arch_compare_and_exchange_bool_64_rel
Anton Blanchard
anton@samba.org
Mon Nov 24 22:26:00 GMT 2014
Fix a typo in the inline assembly.
---
ChangeLog | 5 +++++
sysdeps/powerpc/powerpc64/bits/atomic.h | 2 +-
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/ChangeLog b/ChangeLog
index dac4ad1..64e3a92 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2014-11-25 Anton Blanchard <anton@samba.org>
+
+ * sysdeps/powerpc/bits/atomic.h
+ (__arch_compare_and_exchange_bool_64_rel): Load from mem.
+
2014-11-24 Ryan Cumming <etaoins@gmail.com>
[BZ #17608]
diff --git a/sysdeps/powerpc/powerpc64/bits/atomic.h b/sysdeps/powerpc/powerpc64/bits/atomic.h
index 5c4ebb6..83b5dfe 100644
--- a/sysdeps/powerpc/powerpc64/bits/atomic.h
+++ b/sysdeps/powerpc/powerpc64/bits/atomic.h
@@ -100,7 +100,7 @@
({ \
unsigned long __tmp; \
__asm __volatile (__ARCH_REL_INSTR "\n" \
- "1: ldarx %0,0,%2" MUTEX_HINT_REL "\n" \
+ "1: ldarx %0,0,%1" MUTEX_HINT_REL "\n" \
" subf. %0,%2,%0\n" \
" bne 2f\n" \
" stdcx. %3,0,%1\n" \
--
2.1.0
More information about the Libc-alpha
mailing list