aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/atomic_ops.txt
diff options
context:
space:
mode:
authorRichard Braun <rbraun@sceen.net>2012-12-13 05:07:32 -0500
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>2013-01-08 17:14:55 -0500
commit7e8b1e78ea028cbd32337e2aea574a8466c796bb (patch)
tree5d1f009d9292ad680b8a7a58930bb02139d377e3 /Documentation/atomic_ops.txt
parent52494535103986dbbf689b44d8c2c7efe2132b16 (diff)
Documentation: Memory barrier semantics of atomic_xchg()
Add atomic_xchg() to documentation for atomic operations and memory barriers. Signed-off-by: Richard Braun <rbraun@sceen.net> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Diffstat (limited to 'Documentation/atomic_ops.txt')
-rw-r--r--Documentation/atomic_ops.txt2
1 files changed, 2 insertions, 0 deletions
diff --git a/Documentation/atomic_ops.txt b/Documentation/atomic_ops.txt
index 27f2b21a9d5c..d9ca5be9b471 100644
--- a/Documentation/atomic_ops.txt
+++ b/Documentation/atomic_ops.txt
@@ -253,6 +253,8 @@ This performs an atomic exchange operation on the atomic variable v, setting
253the given new value. It returns the old value that the atomic variable v had 253the given new value. It returns the old value that the atomic variable v had
254just before the operation. 254just before the operation.
255 255
256atomic_xchg requires explicit memory barriers around the operation.
257
256 int atomic_cmpxchg(atomic_t *v, int old, int new); 258 int atomic_cmpxchg(atomic_t *v, int old, int new);
257 259
258This performs an atomic compare exchange operation on the atomic value v, 260This performs an atomic compare exchange operation on the atomic value v,