/arch/ia64/include/asm/ |
D | futex.h | 9 #define __futex_atomic_op1(insn, ret, oldval, uaddr, oparg) \ argument 17 : "+r" (r8), "=r" (oldval) \ 23 #define __futex_atomic_op2(insn, ret, oldval, uaddr, oparg) \ argument 38 : "+r" (r8), "=r" (val), "=&r" (oldval), \ 44 } while (unlikely (val != oldval)); \ 51 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 58 __futex_atomic_op1("xchg4 %1=[%2],%3", ret, oldval, uaddr, in arch_futex_atomic_op_inuser() 62 __futex_atomic_op2("add %3=%3,%5", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 65 __futex_atomic_op2("or %3=%3,%5", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 68 __futex_atomic_op2("and %3=%3,%5", ret, oldval, uaddr, in arch_futex_atomic_op_inuser() [all …]
|
/arch/sh/include/asm/ |
D | futex.h | 21 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument 26 return atomic_futex_op_cmpxchg_inatomic(uval, uaddr, oldval, newval); in futex_atomic_cmpxchg_inatomic() 32 u32 oldval, newval, prev; in arch_futex_atomic_op_inuser() local 36 ret = get_user(oldval, uaddr); in arch_futex_atomic_op_inuser() 45 newval = oldval + oparg; in arch_futex_atomic_op_inuser() 48 newval = oldval | oparg; in arch_futex_atomic_op_inuser() 51 newval = oldval & ~oparg; in arch_futex_atomic_op_inuser() 54 newval = oldval ^ oparg; in arch_futex_atomic_op_inuser() 63 ret = futex_atomic_cmpxchg_inatomic(&prev, uaddr, oldval, newval); in arch_futex_atomic_op_inuser() 64 } while (!ret && prev != oldval); in arch_futex_atomic_op_inuser() [all …]
|
D | spinlock-llsc.h | 29 unsigned long oldval; in arch_spin_lock() local 40 : "=&z" (tmp), "=&r" (oldval) in arch_spin_lock() 63 unsigned long tmp, oldval; in arch_spin_trylock() local 73 : "=&z" (tmp), "=&r" (oldval) in arch_spin_trylock() 78 return oldval; in arch_spin_trylock() 154 unsigned long tmp, oldval; in arch_read_trylock() local 167 : "=&z" (tmp), "=&r" (oldval) in arch_read_trylock() 172 return (oldval > 0); in arch_read_trylock() 177 unsigned long tmp, oldval; in arch_write_trylock() local 190 : "=&z" (tmp), "=&r" (oldval) in arch_write_trylock() [all …]
|
D | futex-llsc.h | 7 u32 oldval, u32 newval) in atomic_futex_op_cmpxchg_inatomic() argument 36 :"r" (uaddr), "i" (-EFAULT), "r" (oldval), "r" (newval) in atomic_futex_op_cmpxchg_inatomic()
|
D | futex-cas.h | 7 u32 oldval, u32 newval) in atomic_futex_op_cmpxchg_inatomic() argument 28 :"r" (oldval), "i" (-EFAULT), "z" (uaddr) in atomic_futex_op_cmpxchg_inatomic()
|
/arch/s390/include/asm/ |
D | futex.h | 10 #define __futex_atomic_op(insn, ret, oldval, newval, uaddr, oparg) \ argument 21 : "=d" (ret), "=&d" (oldval), "=&d" (newval), \ 29 int oldval = 0, newval, ret; in arch_futex_atomic_op_inuser() local 34 ret, oldval, newval, uaddr, oparg); in arch_futex_atomic_op_inuser() 38 ret, oldval, newval, uaddr, oparg); in arch_futex_atomic_op_inuser() 42 ret, oldval, newval, uaddr, oparg); in arch_futex_atomic_op_inuser() 46 ret, oldval, newval, uaddr, oparg); in arch_futex_atomic_op_inuser() 50 ret, oldval, newval, uaddr, oparg); in arch_futex_atomic_op_inuser() 57 *oval = oldval; in arch_futex_atomic_op_inuser() 63 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/openrisc/include/asm/ |
D | futex.h | 11 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ argument 27 : "=&r" (oldval), "=&r" (ret), "+m" (*uaddr) \ 36 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 43 __futex_atomic_op("l.or %1,%4,%4", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 46 __futex_atomic_op("l.add %1,%0,%4", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 49 __futex_atomic_op("l.or %1,%0,%4", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 52 __futex_atomic_op("l.and %1,%0,%4", ret, oldval, uaddr, ~oparg); in arch_futex_atomic_op_inuser() 55 __futex_atomic_op("l.xor %1,%0,%4", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 62 *oval = oldval; in arch_futex_atomic_op_inuser() 69 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/sparc/include/asm/ |
D | futex_64.h | 9 #define __futex_cas_op(insn, ret, oldval, uaddr, oparg) \ argument 29 : "=&r" (ret), "=&r" (oldval), "=&r" (tem) \ 36 int oldval = 0, ret, tem; in arch_futex_atomic_op_inuser() local 43 __futex_cas_op("mov\t%4, %1", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 46 __futex_cas_op("add\t%2, %4, %1", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 49 __futex_cas_op("or\t%2, %4, %1", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 52 __futex_cas_op("andn\t%2, %4, %1", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 55 __futex_cas_op("xor\t%2, %4, %1", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 62 *oval = oldval; in arch_futex_atomic_op_inuser() 69 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/hexagon/include/asm/ |
D | futex.h | 13 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ argument 29 : "=&r" (oldval), "=&r" (ret), "+m" (*uaddr) \ 37 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 44 __futex_atomic_op("%1 = %4\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 47 __futex_atomic_op("%1 = add(%0,%4)\n", ret, oldval, uaddr, in arch_futex_atomic_op_inuser() 51 __futex_atomic_op("%1 = or(%0,%4)\n", ret, oldval, uaddr, in arch_futex_atomic_op_inuser() 56 oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 59 __futex_atomic_op("%1 = xor(%0,%4)\n", ret, oldval, uaddr, in arch_futex_atomic_op_inuser() 67 *oval = oldval; in arch_futex_atomic_op_inuser() 73 futex_atomic_cmpxchg_inatomic(u32 *uval, u32 __user *uaddr, u32 oldval, in futex_atomic_cmpxchg_inatomic() argument [all …]
|
D | bitops.h | 33 int oldval; in test_and_clear_bit() local 42 : "=&r" (oldval) in test_and_clear_bit() 47 return oldval; in test_and_clear_bit() 57 int oldval; in test_and_set_bit() local 66 : "=&r" (oldval) in test_and_set_bit() 72 return oldval; in test_and_set_bit() 83 int oldval; in test_and_change_bit() local 92 : "=&r" (oldval) in test_and_change_bit() 97 return oldval; in test_and_change_bit()
|
/arch/microblaze/include/asm/ |
D | futex.h | 11 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ argument 27 : "=&r" (oldval), "=&r" (ret) \ 35 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 42 __futex_atomic_op("or %1,%4,%4;", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 45 __futex_atomic_op("add %1,%0,%4;", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 48 __futex_atomic_op("or %1,%0,%4;", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 51 __futex_atomic_op("andn %1,%0,%4;", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 54 __futex_atomic_op("xor %1,%0,%4;", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 61 *oval = oldval; in arch_futex_atomic_op_inuser() 68 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/arm/include/asm/ |
D | futex.h | 25 #define __futex_atomic_op(insn, ret, oldval, tmp, uaddr, oparg) \ argument 39 : "=&r" (ret), "=&r" (oldval), "=&r" (tmp) \ 47 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument 70 : "r" (oldval), "r" (newval), "r" (uaddr), "Ir" (-EFAULT) in futex_atomic_cmpxchg_inatomic() 84 #define __futex_atomic_op(insn, ret, oldval, tmp, uaddr, oparg) \ argument 93 : "=&r" (ret), "=&r" (oldval), "=&r" (tmp) \ 101 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument 120 : "r" (oldval), "r" (newval), "r" (uaddr), "Ir" (-EFAULT) in futex_atomic_cmpxchg_inatomic() 135 int oldval = 0, ret, tmp; in arch_futex_atomic_op_inuser() local 146 __futex_atomic_op("mov %0, %4", ret, oldval, tmp, uaddr, oparg); in arch_futex_atomic_op_inuser() [all …]
|
D | cmpxchg.h | 159 unsigned long oldval, res; in __cmpxchg() local 172 : "=&r" (res), "=&r" (oldval) in __cmpxchg() 184 : "=&r" (res), "=&r" (oldval) in __cmpxchg() 197 : "=&r" (res), "=&r" (oldval) in __cmpxchg() 204 oldval = 0; in __cmpxchg() 207 return oldval; in __cmpxchg() 248 unsigned long long oldval; in __cmpxchg64() local 262 : "=&r" (res), "=&r" (oldval), "+Qo" (*ptr) in __cmpxchg64() 266 return oldval; in __cmpxchg64()
|
D | atomic.h | 108 int oldval; in arch_atomic_cmpxchg_relaxed() local 119 : "=&r" (res), "=&r" (oldval), "+Qo" (ptr->counter) in arch_atomic_cmpxchg_relaxed() 124 return oldval; in arch_atomic_cmpxchg_relaxed() 130 int oldval, newval; in arch_atomic_fetch_add_unless() local 145 : "=&r" (oldval), "=&r" (newval), "=&r" (tmp), "+Qo" (v->counter) in arch_atomic_fetch_add_unless() 149 if (oldval != u) in arch_atomic_fetch_add_unless() 152 return oldval; in arch_atomic_fetch_add_unless() 406 s64 oldval; in ATOMIC64_OPS() local 418 : "=&r" (res), "=&r" (oldval), "+Qo" (ptr->counter) in ATOMIC64_OPS() 423 return oldval; in ATOMIC64_OPS() [all …]
|
/arch/alpha/include/asm/ |
D | futex.h | 12 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ argument 25 : "=&r" (oldval), "=&r"(ret) \ 32 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 39 __futex_atomic_op("mov %3,%1\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 42 __futex_atomic_op("addl %0,%3,%1\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 45 __futex_atomic_op("or %0,%3,%1\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 48 __futex_atomic_op("andnot %0,%3,%1\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 51 __futex_atomic_op("xor %0,%3,%1\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 58 *oval = oldval; in arch_futex_atomic_op_inuser() 65 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/nds32/include/asm/ |
D | futex.h | 22 #define __futex_atomic_op(insn, ret, oldval, tmp, uaddr, oparg) \ argument 33 : "=&r" (ret), "=&r" (oldval) \ 38 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument 56 :"r"(oldval), "r"(newval), "r"(uaddr), "i"(-EFAULT) in futex_atomic_cmpxchg_inatomic() 67 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 73 __futex_atomic_op("move %0, %3", ret, oldval, tmp, uaddr, in arch_futex_atomic_op_inuser() 77 __futex_atomic_op("add %0, %1, %3", ret, oldval, tmp, uaddr, in arch_futex_atomic_op_inuser() 81 __futex_atomic_op("or %0, %1, %3", ret, oldval, tmp, uaddr, in arch_futex_atomic_op_inuser() 85 __futex_atomic_op("and %0, %1, %3", ret, oldval, tmp, uaddr, in arch_futex_atomic_op_inuser() 89 __futex_atomic_op("xor %0, %1, %3", ret, oldval, tmp, uaddr, in arch_futex_atomic_op_inuser() [all …]
|
/arch/mips/include/asm/ |
D | futex.h | 22 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ argument 48 : "=r" (ret), "=&r" (oldval), \ 78 : "=r" (ret), "=&r" (oldval), \ 90 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 97 __futex_atomic_op("move $1, %z5", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 102 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 106 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 110 ret, oldval, uaddr, ~oparg); in arch_futex_atomic_op_inuser() 114 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 121 *oval = oldval; in arch_futex_atomic_op_inuser() [all …]
|
/arch/powerpc/include/asm/ |
D | futex.h | 12 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ argument 27 : "=&r" (oldval), "=&r" (ret) \ 34 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 41 __futex_atomic_op("mr %1,%4\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 44 __futex_atomic_op("add %1,%0,%4\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 47 __futex_atomic_op("or %1,%0,%4\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 50 __futex_atomic_op("andc %1,%0,%4\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 53 __futex_atomic_op("xor %1,%0,%4\n", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 60 *oval = oldval; in arch_futex_atomic_op_inuser() 67 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/csky/include/asm/ |
D | futex.h | 14 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ argument 33 : [r] "+r" (ret), [ov] "=&r" (oldval), \ 44 int oldval = 0, ret = 0; in arch_futex_atomic_op_inuser() local 52 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 56 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 60 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 64 ret, oldval, uaddr, ~oparg); in arch_futex_atomic_op_inuser() 68 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 75 *oval = oldval; in arch_futex_atomic_op_inuser() 84 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/xtensa/include/asm/ |
D | futex.h | 39 : [oldval] "=&r" (old), [newval] "=&r" (ret) \ 63 : [oldval] "=&r" (old), [newval] "=&r" (ret), \ 73 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 81 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 85 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 89 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 93 ret, oldval, uaddr, ~oparg); in arch_futex_atomic_op_inuser() 97 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 104 *oval = oldval; in arch_futex_atomic_op_inuser() 114 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/arc/include/asm/ |
D | futex.h | 18 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg)\ argument 39 : "=&r" (ret), "=&r" (oldval) \ 46 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg)\ argument 66 : "=&r" (ret), "=&r" (oldval) \ 76 int oldval = 0, ret; in arch_futex_atomic_op_inuser() local 87 __futex_atomic_op("mov %0, %3", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 91 __futex_atomic_op("add %0, %1, %3", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 94 __futex_atomic_op("or %0, %1, %3", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 97 __futex_atomic_op("bic %0, %1, %3", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 100 __futex_atomic_op("xor %0, %1, %3", ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() [all …]
|
/arch/riscv/include/asm/ |
D | futex.h | 21 #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ argument 37 : [r] "+r" (ret), [ov] "=&r" (oldval), \ 47 int oldval = 0, ret = 0; in arch_futex_atomic_op_inuser() local 55 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 59 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 63 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 67 ret, oldval, uaddr, ~oparg); in arch_futex_atomic_op_inuser() 71 ret, oldval, uaddr, oparg); in arch_futex_atomic_op_inuser() 78 *oval = oldval; in arch_futex_atomic_op_inuser() 85 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/arm64/include/asm/ |
D | futex.h | 15 #define __futex_atomic_op(insn, ret, oldval, uaddr, tmp, oparg) \ argument 38 : "=&r" (ret), "=&r" (oldval), "+Q" (*uaddr), "=&r" (tmp), \ 48 int oldval = 0, ret, tmp; in arch_futex_atomic_op_inuser() local 57 ret, oldval, uaddr, tmp, oparg); in arch_futex_atomic_op_inuser() 61 ret, oldval, uaddr, tmp, oparg); in arch_futex_atomic_op_inuser() 65 ret, oldval, uaddr, tmp, oparg); in arch_futex_atomic_op_inuser() 69 ret, oldval, uaddr, tmp, ~oparg); in arch_futex_atomic_op_inuser() 73 ret, oldval, uaddr, tmp, oparg); in arch_futex_atomic_op_inuser() 80 *oval = oldval; in arch_futex_atomic_op_inuser() 87 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument [all …]
|
/arch/x86/include/asm/ |
D | futex.h | 17 int oldval = 0, ret; \ 21 : "=r" (oldval), "=r" (ret), "+m" (*uaddr) \ 25 *oval = oldval; \ 31 int oldval = 0, ret, tem; \ 40 : "=&a" (oldval), "=&r" (ret), \ 45 *oval = oldval; \ 83 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument 93 : "+r" (ret), "=a" (oldval), "+m" (*uaddr) in futex_atomic_cmpxchg_inatomic() 94 : "r" (newval), "1" (oldval) in futex_atomic_cmpxchg_inatomic() 98 *uval = oldval; in futex_atomic_cmpxchg_inatomic()
|
/arch/parisc/include/asm/ |
D | futex.h | 39 int oldval, ret; in arch_futex_atomic_op_inuser() local 45 if (unlikely(get_user(oldval, uaddr) != 0)) in arch_futex_atomic_op_inuser() 49 tmp = oldval; in arch_futex_atomic_op_inuser() 78 *oval = oldval; in arch_futex_atomic_op_inuser() 85 u32 oldval, u32 newval) in futex_atomic_cmpxchg_inatomic() argument 111 if (val == oldval && unlikely(put_user(newval, uaddr) != 0)) { in futex_atomic_cmpxchg_inatomic()
|