/netbsd-src/sys/arch/sparc/include/ |
H A D | lock.h | 39 #if __SIMPLELOCK_UNLOCKED != 0 40 #error __SIMPLELOCK_UNLOCKED must be 0 for this implementation 83 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 89 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 102 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 117 while (__ldstub(alp) != __SIMPLELOCK_UNLOCKED) { in __cpu_simple_lock() 118 while (*alp != __SIMPLELOCK_UNLOCKED) in __cpu_simple_lock() 138 return (__ldstub(alp) == __SIMPLELOCK_UNLOCKED); in __cpu_simple_lock_try() 153 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
/netbsd-src/sys/arch/arm/include/ |
H A D | lock.h | 53 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 59 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 161 *__alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 171 } while (__arm_load_exclusive(__alp) != __SIMPLELOCK_UNLOCKED in __cpu_simple_lock() 175 while (__swp(__SIMPLELOCK_LOCKED, __alp) != __SIMPLELOCK_UNLOCKED) in __cpu_simple_lock() 189 if (__arm_load_exclusive(__alp) != __SIMPLELOCK_UNLOCKED) { in __cpu_simple_lock_try() 196 return (__swp(__SIMPLELOCK_LOCKED, __alp) == __SIMPLELOCK_UNLOCKED); in __cpu_simple_lock_try() 210 :: "r"(__SIMPLELOCK_UNLOCKED), "r"(__alp) : "memory"); in __cpu_simple_unlock() 213 :: "r"(__SIMPLELOCK_UNLOCKED), "r"(__alp) : "memory"); in __cpu_simple_unlock() 217 *__alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
H A D | types.h | 80 #define __SIMPLELOCK_UNLOCKED 0 macro
|
/netbsd-src/sys/sys/ |
H A D | common_lock.h | 43 return *__ptr != __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_LOCKED_P() 49 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 56 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 58 __atomic_store_n(__ptr, __SIMPLELOCK_UNLOCKED, __ATOMIC_RELAXED); in __cpu_simple_lock_clear() 76 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 78 __atomic_store_n(__ptr, __SIMPLELOCK_UNLOCKED, __ATOMIC_RELAXED); in __cpu_simple_lock_init() 93 return __atomic_exchange_n(__ptr, __SIMPLELOCK_LOCKED, __ATOMIC_ACQUIRE) == __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_try() 99 __atomic_store_n(__ptr, __SIMPLELOCK_UNLOCKED, __ATOMIC_RELEASE); in __cpu_simple_unlock()
|
/netbsd-src/sys/arch/powerpc/include/ |
H A D | lock.h | 48 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 54 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 66 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 92 : "r"(alp), "I"(__SIMPLELOCK_UNLOCKED), "r"(__SIMPLELOCK_LOCKED) in __cpu_simple_lock() 119 : "r"(alp), "I"(__SIMPLELOCK_UNLOCKED), "r"(__SIMPLELOCK_LOCKED), in __cpu_simple_lock_try() 123 return (old == __SIMPLELOCK_UNLOCKED); in __cpu_simple_lock_try() 130 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
/netbsd-src/sys/arch/mips/include/ |
H A D | lock.h | 49 return *__ptr != __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_LOCKED_P() 55 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 61 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 128 __SIMPLELOCK_UNLOCKED, __SIMPLELOCK_LOCKED) == in __cpu_simple_lock_try() 129 __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_try() 138 *lp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 164 *lp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
/netbsd-src/sys/arch/or1k/include/ |
H A D | lock.h | 41 return *__ptr != __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_LOCKED_P() 47 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 56 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 76 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 111 [unlocked] "n" (__SIMPLELOCK_UNLOCKED) in __cpu_simple_lock() 134 return oldval == __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_try() 145 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
H A D | types.h | 69 #define __SIMPLELOCK_UNLOCKED 0 macro
|
/netbsd-src/sys/arch/ia64/include/ |
H A D | lock.h | 48 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 62 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 85 *lockp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 98 return val == __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_try() 115 *lockp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
H A D | types.h | 67 #define __SIMPLELOCK_UNLOCKED 0 macro
|
/netbsd-src/sys/arch/x86/include/ |
H A D | lock.h | 50 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 64 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 90 *lockp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 103 return val == __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_try() 172 *lockp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
/netbsd-src/lib/libpthread/ |
H A D | pthread_types.h | 108 #if __SIMPLELOCK_UNLOCKED != 0 109 #error __CPU_SIMPLE_LOCK_PAD incompatible with __SIMPLELOCK_UNLOCKED == 0 151 _PTHREAD_MUTEX_INI(ptm_errorcheck, __SIMPLELOCK_UNLOCKED), \ 186 __SIMPLELOCK_UNLOCKED, \ 220 __SIMPLELOCK_UNLOCKED, \ 241 __SIMPLELOCK_UNLOCKED, \
|
/netbsd-src/sys/arch/m68k/include/ |
H A D | lock.h | 48 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 55 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 62 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 106 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
H A D | types.h | 69 #define __SIMPLELOCK_UNLOCKED 0 macro
|
/netbsd-src/sys/arch/acorn32/include/ |
H A D | lock.h | 58 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 65 while (__swp(__SIMPLELOCK_LOCKED, alp) != __SIMPLELOCK_UNLOCKED) in __cpu_simple_lock() 75 __result = __swp(__SIMPLELOCK_LOCKED, alp) == __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_try() 86 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
/netbsd-src/sys/arch/sh3/include/ |
H A D | lock.h | 57 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 63 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 76 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 111 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock()
|
H A D | types.h | 70 #define __SIMPLELOCK_UNLOCKED 0 macro
|
/netbsd-src/sys/arch/usermode/include/ |
H A D | lock.h | 35 *lockp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init() 57 *lockp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_unlock() 69 return *lockp == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P()
|
H A D | types.h | 87 #define __SIMPLELOCK_UNLOCKED 0 macro
|
/netbsd-src/sys/arch/alpha/include/ |
H A D | lock.h | 53 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 59 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 72 *alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init()
|
H A D | types.h | 69 #define __SIMPLELOCK_UNLOCKED 0 macro
|
/netbsd-src/sys/arch/vax/include/ |
H A D | lock.h | 50 return *__ptr == __SIMPLELOCK_UNLOCKED; in __SIMPLELOCK_UNLOCKED_P() 56 *__ptr = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_clear() 69 *__alp = __SIMPLELOCK_UNLOCKED; in __cpu_simple_lock_init()
|
H A D | types.h | 70 #define __SIMPLELOCK_UNLOCKED 0 macro
|
/netbsd-src/sys/rump/librump/rumpkern/ |
H A D | atomic_cas_generic.c | 44 #define I2 __SIMPLELOCK_UNLOCKED, __SIMPLELOCK_UNLOCKED,
|
/netbsd-src/sys/arch/hppa/include/ |
H A D | types.h | 84 #define __SIMPLELOCK_UNLOCKED { { 1, 1, 1, 1 } } macro
|