Lines Matching refs:v
21 atomic##bit##_set(&v, v0); \
23 atomic##bit##_##op(val, &v); \
25 WARN(atomic##bit##_read(&v) != r, "%Lx != %Lx\n", \
26 (unsigned long long)atomic##bit##_read(&v), \
37 atomic_t v; in test_atomic() local
50 #define INIT(c) do { atomic64_set(&v, c); r = c; } while (0)
59 atomic64_t v = ATOMIC64_INIT(v0); in test_atomic64() local
61 BUG_ON(v.counter != r); in test_atomic64()
63 atomic64_set(&v, v1); in test_atomic64()
65 BUG_ON(v.counter != r); in test_atomic64()
66 BUG_ON(atomic64_read(&v) != r); in test_atomic64()
79 BUG_ON(atomic64_add_return(onestwos, &v) != r); in test_atomic64()
80 BUG_ON(v.counter != r); in test_atomic64()
84 BUG_ON(atomic64_add_return(-one, &v) != r); in test_atomic64()
85 BUG_ON(v.counter != r); in test_atomic64()
89 BUG_ON(atomic64_sub_return(onestwos, &v) != r); in test_atomic64()
90 BUG_ON(v.counter != r); in test_atomic64()
94 BUG_ON(atomic64_sub_return(-one, &v) != r); in test_atomic64()
95 BUG_ON(v.counter != r); in test_atomic64()
98 atomic64_inc(&v); in test_atomic64()
100 BUG_ON(v.counter != r); in test_atomic64()
104 BUG_ON(atomic64_inc_return(&v) != r); in test_atomic64()
105 BUG_ON(v.counter != r); in test_atomic64()
108 atomic64_dec(&v); in test_atomic64()
110 BUG_ON(v.counter != r); in test_atomic64()
114 BUG_ON(atomic64_dec_return(&v) != r); in test_atomic64()
115 BUG_ON(v.counter != r); in test_atomic64()
118 BUG_ON(atomic64_xchg(&v, v1) != v0); in test_atomic64()
120 BUG_ON(v.counter != r); in test_atomic64()
123 BUG_ON(atomic64_cmpxchg(&v, v0, v1) != v0); in test_atomic64()
125 BUG_ON(v.counter != r); in test_atomic64()
128 BUG_ON(atomic64_cmpxchg(&v, v2, v1) != v0); in test_atomic64()
129 BUG_ON(v.counter != r); in test_atomic64()
132 BUG_ON(atomic64_add_unless(&v, one, v0)); in test_atomic64()
133 BUG_ON(v.counter != r); in test_atomic64()
136 BUG_ON(!atomic64_add_unless(&v, one, v1)); in test_atomic64()
138 BUG_ON(v.counter != r); in test_atomic64()
142 BUG_ON(atomic64_dec_if_positive(&v) != (onestwos - 1)); in test_atomic64()
144 BUG_ON(v.counter != r); in test_atomic64()
147 BUG_ON(atomic64_dec_if_positive(&v) != -one); in test_atomic64()
148 BUG_ON(v.counter != r); in test_atomic64()
151 BUG_ON(atomic64_dec_if_positive(&v) != (-one - one)); in test_atomic64()
152 BUG_ON(v.counter != r); in test_atomic64()
158 BUG_ON(!atomic64_inc_not_zero(&v)); in test_atomic64()
160 BUG_ON(v.counter != r); in test_atomic64()
163 BUG_ON(atomic64_inc_not_zero(&v)); in test_atomic64()
164 BUG_ON(v.counter != r); in test_atomic64()
167 BUG_ON(!atomic64_inc_not_zero(&v)); in test_atomic64()
169 BUG_ON(v.counter != r); in test_atomic64()