]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Add a new atomic_fetchadd() primitive that atomically adds a value to a
authorjhb <jhb@FreeBSD.org>
Tue, 27 Sep 2005 17:39:11 +0000 (17:39 +0000)
committerjhb <jhb@FreeBSD.org>
Tue, 27 Sep 2005 17:39:11 +0000 (17:39 +0000)
commit89caa56972d968272278a67fe10affb38d9e88eb
tree368df1c62ea6aa397797927efbf9c7ccc4b3b92e
parentaa790ae8700e7fed7ef83f2549c6bc53d6ae7f8f
Add a new atomic_fetchadd() primitive that atomically adds a value to a
variable and returns the previous value of the variable.

Tested on: i386, alpha, sparc64, arm (cognet)
Reviewed by: arch@
Submitted by: cognet (arm)
MFC after: 1 week
sys/alpha/include/atomic.h
sys/amd64/include/atomic.h
sys/arm/include/atomic.h
sys/i386/include/atomic.h
sys/ia64/include/atomic.h
sys/powerpc/include/atomic.h
sys/sparc64/include/atomic.h