Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid S. Miller <davem@nuts.davemloft.net>2005-02-10 03:17:56 -0800
committerDavid S. Miller <davem@nuts.davemloft.net>2005-02-10 03:17:56 -0800
commit8bf955856715e9b428b6633364f5441a6475f5a3 (patch)
treed0e12977663e651cff9bf65bb9ebef3a0eeb628d
parentd46c65c54388517b4e2c1f9fb995d026bcd4d80e (diff)
[DOC]: Fix typo in atomic_ops.txt
s/smb_/smp_/ Noticed by Werner Almesberger. Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--Documentation/atomic_ops.txt18
1 files changed, 9 insertions, 9 deletions
diff --git a/Documentation/atomic_ops.txt b/Documentation/atomic_ops.txt
index 6f8793752022..8eedaa24f5e2 100644
--- a/Documentation/atomic_ops.txt
+++ b/Documentation/atomic_ops.txt
@@ -119,15 +119,15 @@ If a caller requires memory barrier semantics around an atomic_t
operation which does not return a value, a set of interfaces are
defined which accomplish this:
- void smb_mb__before_atomic_dec(void);
- void smb_mb__after_atomic_dec(void);
- void smb_mb__before_atomic_inc(void);
- void smb_mb__after_atomic_dec(void);
+ void smp_mb__before_atomic_dec(void);
+ void smp_mb__after_atomic_dec(void);
+ void smp_mb__before_atomic_inc(void);
+ void smp_mb__after_atomic_dec(void);
-For example, smb_mb__before_atomic_dec() can be used like so:
+For example, smp_mb__before_atomic_dec() can be used like so:
obj->dead = 1;
- smb_mb__before_atomic_dec();
+ smp_mb__before_atomic_dec();
atomic_dec(&obj->ref_count);
It makes sure that all memory operations preceeding the atomic_dec()
@@ -136,14 +136,14 @@ operation. In the above example, it guarentees that the assignment of
"1" to obj->dead will be globally visible to other cpus before the
atomic counter decrement.
-Without the explicitl smb_mb__before_atomic_dec() call, the
+Without the explicitl smp_mb__before_atomic_dec() call, the
implementation could legally allow the atomic counter update visible
to other cpus before the "obj->dead = 1;" assignment.
The other three interfaces listed are used to provide explicit
ordering with respect to memory operations after an atomic_dec() call
-(smb_mb__after_atomic_dec()) and around atomic_inc() calls
-(smb_mb__{before,after}_atomic_inc()).
+(smp_mb__after_atomic_dec()) and around atomic_inc() calls
+(smp_mb__{before,after}_atomic_inc()).
A missing memory barrier in the cases where they are required by the
atomic_t implementation above can have disasterous results. Here is