public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* atomics: document that linux expects certain atomic behaviour from unsigned long
@ 2009-01-03 12:44 Pavel Machek
  2009-01-03 20:19 ` Alan Cox
  0 siblings, 1 reply; 17+ messages in thread
From: Pavel Machek @ 2009-01-03 12:44 UTC (permalink / raw)
  To: kernel list, Andrew Morton, mtk.manpages, rdunlap, linux-doc

Linux relies on unsigned long to behave like atomic for read/write.
diff --git a/Documentation/atomic_ops.txt b/Documentation/atomic_ops.txt
index 4ef2450..0a7d180 100644
--- a/Documentation/atomic_ops.txt
+++ b/Documentation/atomic_ops.txt
@@ -21,6 +21,9 @@ local_t is very similar to atomic_t. If the counter is per CPU and only
 updated by one CPU, local_t is probably more appropriate. Please see
 Documentation/local_ops.txt for the semantics of local_t.
 
+unsigned long can be used instead of atomic_t, if all you
+need is atomic setting and atomic reading.
+
 The first operations to implement for atomic_t's are the initializers and
 plain reads.
 

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

^ permalink raw reply related	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2009-01-05 22:01 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-03 12:44 atomics: document that linux expects certain atomic behaviour from unsigned long Pavel Machek
2009-01-03 20:19 ` Alan Cox
2009-01-03 20:27   ` Pavel Machek
2009-01-03 20:30     ` Alan Cox
2009-01-03 20:56       ` Pavel Machek
2009-01-03 23:01         ` david
2009-01-03 23:14         ` Alan Cox
2009-01-05 10:54           ` Nick Piggin
2009-01-05 11:23             ` Alan Cox
2009-01-05 12:00               ` Nick Piggin
2009-01-05 16:05                 ` Paul E. McKenney
2009-01-05 16:25                   ` Nick Piggin
2009-01-05 17:30                     ` Paul E. McKenney
2009-01-05 18:25                       ` Nick Piggin
2009-01-05 22:01                         ` Paul E. McKenney
2009-01-03 23:53         ` Robert Hancock
2009-01-04 18:05       ` Tilman Schmidt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox