From: Rusty Russell <rusty@rustcorp.com.au>
To: torvalds@transmeta.com
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] TRIVIAL I: 2.5.6-pre3. Documentation
Date: Thu, 07 Mar 2002 18:37:02 +1100 [thread overview]
Message-ID: <E16isSU-0006aV-00@wagner.rustcorp.com.au> (raw)
Linus, please apply. atomic ops are *not* barriers any more.
Sebastian Wilhelmi <wilhelmi@ira.uka.de>: Re: Question on your "Unreliable Guide To Locking":
> Yes, this is no longer true. The modern assumptions are that they are
> not barriers.
diff -urN -I \$.*\$ --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.5.6-pre3/Documentation/DocBook/kernel-locking.tmpl trivial-2.5.6-pre3/Documentation/DocBook/kernel-locking.tmpl
--- linux-2.5.6-pre3/Documentation/DocBook/kernel-locking.tmpl Sun May 20 10:43:05 2001
+++ trivial-2.5.6-pre3/Documentation/DocBook/kernel-locking.tmpl Thu Mar 7 18:20:33 2002
@@ -788,8 +788,18 @@
</para>
<para>
- Note that the atomic operations are defined to act as both
- read and write barriers on all platforms.
+ Note that the atomic operations do in general not act as memory
+ barriers. Instead you can insert a memory barrier before or
+ after <function>atomic_inc()</function> or
+ <function>atomic_dec()</function> by inserting
+ <function>smp_mb__before_atomic_inc()</function>,
+ <function>smp_mb__after_atomic_inc()</function>,
+ <function>smp_mb__before_atomic_dec()</function> or
+ <function>smp_mb__after_atomic_dec()</function>
+ respectively. The advantage of using those macros instead of
+ <function>smp_mb()</function> is, that they are cheaper on some
+ platforms.
+ <!-- Sebastian Wilhelmi <seppi@seppi.de> 2002-03-04 -->
</para>
</sect1>
--
Anyone who quotes me in their sig is an idiot. -- Rusty Russell.
reply other threads:[~2002-03-07 7:34 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=E16isSU-0006aV-00@wagner.rustcorp.com.au \
--to=rusty@rustcorp.com.au \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®