Skip to content

Commit a22e5f5

Browse files
committed
arch: Remove __ARCH_HAVE_CMPXCHG
We removed the only user of this define in the rtmutex code. Get rid of it. Signed-off-by: Thomas Gleixner <[email protected]> Cc: Sebastian Andrzej Siewior <[email protected]>
1 parent cede884 commit a22e5f5

File tree

17 files changed

+0
-31
lines changed

17 files changed

+0
-31
lines changed

arch/alpha/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,4 @@
6666
#undef __ASM__MB
6767
#undef ____cmpxchg
6868

69-
#define __HAVE_ARCH_CMPXCHG 1
70-
7169
#endif /* _ALPHA_CMPXCHG_H */

arch/avr32/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,6 @@ extern unsigned long __cmpxchg_u64_unsupported_on_32bit_kernels(
7070
if something tries to do an invalid cmpxchg(). */
7171
extern void __cmpxchg_called_with_bad_pointer(void);
7272

73-
#define __HAVE_ARCH_CMPXCHG 1
74-
7573
static inline unsigned long __cmpxchg(volatile void *ptr, unsigned long old,
7674
unsigned long new, int size)
7775
{

arch/hexagon/include/asm/cmpxchg.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ static inline unsigned long __xchg(unsigned long x, volatile void *ptr,
6464
* looks just like atomic_cmpxchg on our arch currently with a bunch of
6565
* variable casting.
6666
*/
67-
#define __HAVE_ARCH_CMPXCHG 1
6867

6968
#define cmpxchg(ptr, old, new) \
7069
({ \

arch/ia64/include/uapi/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,6 @@ extern void ia64_xchg_called_with_bad_pointer(void);
6161
* indicated by comparing RETURN with OLD.
6262
*/
6363

64-
#define __HAVE_ARCH_CMPXCHG 1
65-
6664
/*
6765
* This function doesn't exist, so you'll get a linker error
6866
* if something tries to do an invalid cmpxchg().

arch/m32r/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,6 @@ __xchg_local(unsigned long x, volatile void *ptr, int size)
107107
((__typeof__(*(ptr)))__xchg_local((unsigned long)(x), (ptr), \
108108
sizeof(*(ptr))))
109109

110-
#define __HAVE_ARCH_CMPXCHG 1
111-
112110
static inline unsigned long
113111
__cmpxchg_u32(volatile unsigned int *p, unsigned int old, unsigned int new)
114112
{

arch/m68k/include/asm/cmpxchg.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,6 @@ extern unsigned long __invalid_cmpxchg_size(volatile void *,
9090
* indicated by comparing RETURN with OLD.
9191
*/
9292
#ifdef CONFIG_RMW_INSNS
93-
#define __HAVE_ARCH_CMPXCHG 1
9493

9594
static inline unsigned long __cmpxchg(volatile void *p, unsigned long old,
9695
unsigned long new, int size)

arch/metag/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,6 @@ static inline unsigned long __cmpxchg(volatile void *ptr, unsigned long old,
5151
return old;
5252
}
5353

54-
#define __HAVE_ARCH_CMPXCHG 1
55-
5654
#define cmpxchg(ptr, o, n) \
5755
({ \
5856
__typeof__(*(ptr)) _o_ = (o); \

arch/mips/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,6 @@ static inline unsigned long __xchg(unsigned long x, volatile void * ptr, int siz
138138
__xchg((unsigned long)(x), (ptr), sizeof(*(ptr)))); \
139139
})
140140

141-
#define __HAVE_ARCH_CMPXCHG 1
142-
143141
#define __cmpxchg_asm(ld, st, m, old, new) \
144142
({ \
145143
__typeof(*(m)) __ret; \

arch/parisc/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,6 @@ __xchg(unsigned long x, __volatile__ void *ptr, int size)
4646
#define xchg(ptr, x) \
4747
((__typeof__(*(ptr)))__xchg((unsigned long)(x), (ptr), sizeof(*(ptr))))
4848

49-
#define __HAVE_ARCH_CMPXCHG 1
50-
5149
/* bug catcher for when unsupported size is used - won't link */
5250
extern void __cmpxchg_called_with_bad_pointer(void);
5351

arch/powerpc/include/asm/cmpxchg.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,6 @@ __xchg_local(volatile void *ptr, unsigned long x, unsigned int size)
144144
* Compare and exchange - if *p == old, set it to new,
145145
* and return the old value of *p.
146146
*/
147-
#define __HAVE_ARCH_CMPXCHG 1
148147

149148
static __always_inline unsigned long
150149
__cmpxchg_u32(volatile unsigned int *p, unsigned long old, unsigned long new)

arch/s390/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,6 @@
3232
__old; \
3333
})
3434

35-
#define __HAVE_ARCH_CMPXCHG
36-
3735
#define __cmpxchg_double_op(p1, p2, o1, o2, n1, n2, insn) \
3836
({ \
3937
register __typeof__(*(p1)) __old1 asm("2") = (o1); \

arch/score/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,6 @@ static inline unsigned long __cmpxchg(volatile unsigned long *m,
4242
(unsigned long)(o), \
4343
(unsigned long)(n)))
4444

45-
#define __HAVE_ARCH_CMPXCHG 1
46-
4745
#include <asm-generic/cmpxchg-local.h>
4846

4947
#endif /* _ASM_SCORE_CMPXCHG_H */

arch/sh/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,6 @@ extern void __xchg_called_with_bad_pointer(void);
4646
* if something tries to do an invalid cmpxchg(). */
4747
extern void __cmpxchg_called_with_bad_pointer(void);
4848

49-
#define __HAVE_ARCH_CMPXCHG 1
50-
5149
static inline unsigned long __cmpxchg(volatile void * ptr, unsigned long old,
5250
unsigned long new, int size)
5351
{

arch/sparc/include/asm/cmpxchg_32.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ static inline unsigned long __xchg(unsigned long x, __volatile__ void * ptr, int
3434
*
3535
* Cribbed from <asm-parisc/atomic.h>
3636
*/
37-
#define __HAVE_ARCH_CMPXCHG 1
3837

3938
/* bug catcher for when unsupported size is used - won't link */
4039
void __cmpxchg_called_with_bad_pointer(void);

arch/sparc/include/asm/cmpxchg_64.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,6 @@ static inline unsigned long __xchg(unsigned long x, __volatile__ void * ptr,
6565

6666
#include <asm-generic/cmpxchg-local.h>
6767

68-
#define __HAVE_ARCH_CMPXCHG 1
69-
7068
static inline unsigned long
7169
__cmpxchg_u32(volatile int *m, int old, int new)
7270
{

arch/tile/include/asm/atomic_64.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,9 +105,6 @@ static inline long atomic64_add_unless(atomic64_t *v, long a, long u)
105105

106106
#define atomic64_inc_not_zero(v) atomic64_add_unless((v), 1, 0)
107107

108-
/* Define this to indicate that cmpxchg is an efficient operation. */
109-
#define __HAVE_ARCH_CMPXCHG
110-
111108
#endif /* !__ASSEMBLY__ */
112109

113110
#endif /* _ASM_TILE_ATOMIC_64_H */

arch/x86/include/asm/cmpxchg.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,6 @@
44
#include <linux/compiler.h>
55
#include <asm/alternative.h> /* Provides LOCK_PREFIX */
66

7-
#define __HAVE_ARCH_CMPXCHG 1
8-
97
/*
108
* Non-existant functions to indicate usage errors at link time
119
* (or compile-time if the compiler implements __compiletime_error().

0 commit comments

Comments
 (0)