diff options
Diffstat (limited to 'arch/parisc/include/asm/atomic.h')
-rw-r--r-- | arch/parisc/include/asm/atomic.h | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/arch/parisc/include/asm/atomic.h b/arch/parisc/include/asm/atomic.h index 7eeaff944360..8bc9e96699b2 100644 --- a/arch/parisc/include/asm/atomic.h +++ b/arch/parisc/include/asm/atomic.h | |||
@@ -222,13 +222,13 @@ static __inline__ int atomic_add_unless(atomic_t *v, int a, int u) | |||
222 | 222 | ||
223 | #define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0) | 223 | #define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0) |
224 | 224 | ||
225 | #define atomic_add(i,v) ((void)(__atomic_add_return( ((int)(i)),(v)))) | 225 | #define atomic_add(i,v) ((void)(__atomic_add_return( (i),(v)))) |
226 | #define atomic_sub(i,v) ((void)(__atomic_add_return(-((int)(i)),(v)))) | 226 | #define atomic_sub(i,v) ((void)(__atomic_add_return(-(i),(v)))) |
227 | #define atomic_inc(v) ((void)(__atomic_add_return( 1,(v)))) | 227 | #define atomic_inc(v) ((void)(__atomic_add_return( 1,(v)))) |
228 | #define atomic_dec(v) ((void)(__atomic_add_return( -1,(v)))) | 228 | #define atomic_dec(v) ((void)(__atomic_add_return( -1,(v)))) |
229 | 229 | ||
230 | #define atomic_add_return(i,v) (__atomic_add_return( ((int)(i)),(v))) | 230 | #define atomic_add_return(i,v) (__atomic_add_return( (i),(v))) |
231 | #define atomic_sub_return(i,v) (__atomic_add_return(-((int)(i)),(v))) | 231 | #define atomic_sub_return(i,v) (__atomic_add_return(-(i),(v))) |
232 | #define atomic_inc_return(v) (__atomic_add_return( 1,(v))) | 232 | #define atomic_inc_return(v) (__atomic_add_return( 1,(v))) |
233 | #define atomic_dec_return(v) (__atomic_add_return( -1,(v))) | 233 | #define atomic_dec_return(v) (__atomic_add_return( -1,(v))) |
234 | 234 | ||
@@ -336,7 +336,11 @@ static __inline__ int atomic64_add_unless(atomic64_t *v, long a, long u) | |||
336 | 336 | ||
337 | #define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0) | 337 | #define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0) |
338 | 338 | ||
339 | #endif /* CONFIG_64BIT */ | 339 | #else /* CONFIG_64BIT */ |
340 | |||
341 | #include <asm-generic/atomic64.h> | ||
342 | |||
343 | #endif /* !CONFIG_64BIT */ | ||
340 | 344 | ||
341 | #include <asm-generic/atomic-long.h> | 345 | #include <asm-generic/atomic-long.h> |
342 | 346 | ||