[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-caa17d49f9a5cc09b3bbb101dc640f914f3b4ff7@git.kernel.org>
Date: Wed, 10 Sep 2014 10:31:24 -0700
From: tip-bot for Peter Zijlstra <tipbot@...or.com>
To: linux-tip-commits@...r.kernel.org
Cc: linux-kernel@...r.kernel.org, hpa@...or.com, mingo@...nel.org,
torvalds@...ux-foundation.org, peterz@...radead.org,
davem@...emloft.net, linux@...ck-us.net, tglx@...utronix.de,
sfr@...b.auug.org.au
Subject: [tip:locking/arch] locking, sparc64: Fix atomics
Commit-ID: caa17d49f9a5cc09b3bbb101dc640f914f3b4ff7
Gitweb: http://git.kernel.org/tip/caa17d49f9a5cc09b3bbb101dc640f914f3b4ff7
Author: Peter Zijlstra <peterz@...radead.org>
AuthorDate: Tue, 2 Sep 2014 11:40:16 +0200
Committer: Ingo Molnar <mingo@...nel.org>
CommitDate: Wed, 10 Sep 2014 11:45:04 +0200
locking, sparc64: Fix atomics
The patch folding the atomic ops had a silly fail in the _return primitives.
Fixes: 4f3316c2b5fe ("locking,arch,sparc: Fold atomic_ops")
Reported-by: Guenter Roeck <linux@...ck-us.net>
Tested-by: Guenter Roeck <linux@...ck-us.net>
Signed-off-by: Peter Zijlstra (Intel) <peterz@...radead.org>
Cc: "David S. Miller" <davem@...emloft.net>
Cc: Stephen Rothwell <sfr@...b.auug.org.au>
Cc: David S. Miller <davem@...emloft.net>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: sparclinux@...r.kernel.org
Link: http://lkml.kernel.org/r/20140902094016.GD31157@worktop.ger.corp.intel.com
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
arch/sparc/lib/atomic_64.S | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/sparc/lib/atomic_64.S b/arch/sparc/lib/atomic_64.S
index 96d70b4..05dac43 100644
--- a/arch/sparc/lib/atomic_64.S
+++ b/arch/sparc/lib/atomic_64.S
@@ -37,7 +37,7 @@ ENTRY(atomic_##op##_return) /* %o0 = increment, %o1 = atomic_ptr */ \
cas [%o1], %g1, %g7; \
cmp %g1, %g7; \
bne,pn %icc, BACKOFF_LABEL(2f, 1b); \
- add %g1, %o0, %g1; \
+ op %g1, %o0, %g1; \
retl; \
sra %g1, 0, %o0; \
2: BACKOFF_SPIN(%o2, %o3, 1b); \
@@ -76,7 +76,7 @@ ENTRY(atomic64_##op##_return) /* %o0 = increment, %o1 = atomic_ptr */ \
bne,pn %xcc, BACKOFF_LABEL(2f, 1b); \
nop; \
retl; \
- add %g1, %o0, %o0; \
+ op %g1, %o0, %o0; \
2: BACKOFF_SPIN(%o2, %o3, 1b); \
ENDPROC(atomic64_##op##_return);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists