aboutsummaryrefslogtreecommitdiffstats
path: root/libcutils
diff options
context:
space:
mode:
authorCarl Shapiro <cshapiro@google.com>2011-01-23 14:07:02 -0800
committerCarl Shapiro <cshapiro@google.com>2011-01-23 14:09:17 -0800
commit0a16d839698e46e87268707e79e66f51a42b932e (patch)
tree6b3e6e0d3bea90ebf6fde39f9d1ca98d31446b84 /libcutils
parent88af5ff47dc6eb371c3ee597b5a646fa0e5a8578 (diff)
downloadsystem_core-0a16d839698e46e87268707e79e66f51a42b932e.tar.gz
system_core-0a16d839698e46e87268707e79e66f51a42b932e.tar.bz2
system_core-0a16d839698e46e87268707e79e66f51a42b932e.zip
Remove unconditional swap from the android atomic operations suite.
Bug: 3381237 Change-Id: I7bdc7c8eb4c1cc6303d96e40ca2f196a007c4dd2
Diffstat (limited to 'libcutils')
-rw-r--r--libcutils/atomic-android-sh.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/libcutils/atomic-android-sh.c b/libcutils/atomic-android-sh.c
index f8f1f57b..8bac68ad 100644
--- a/libcutils/atomic-android-sh.c
+++ b/libcutils/atomic-android-sh.c
@@ -113,18 +113,6 @@ int32_t android_atomic_or(int32_t value, volatile int32_t* addr) {
return oldValue;
}
-int32_t android_atomic_acquire_swap(int32_t value, volatile int32_t* addr) {
- return android_atomic_release_swap(value, addr);
-}
-
-int32_t android_atomic_release_swap(int32_t value, volatile int32_t* addr) {
- int32_t oldValue;
- do {
- oldValue = *addr;
- } while (android_atomic_cmpxchg(oldValue, value, addr));
- return oldValue;
-}
-
int android_atomic_acquire_cmpxchg(int32_t oldvalue, int32_t newvalue,
volatile int32_t* addr) {
return android_atomic_release_cmpxchg(oldValue, newValue, addr);