Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1257169

[PATCH 1/4] arch,cmpxchg: Remove tas() definitions

From Davidlohr Bueso <dave@stgolabs.net>
Newsgroups linux.kernel
Subject [PATCH 1/4] arch,cmpxchg: Remove tas() definitions
Date 2015-10-27 21:00 +0100
Message-ID <qoizw-SL-13@gated-at.bofh.it> (permalink)
References <qoizw-SL-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


It seems that 5dc12ddee93 (Remove tas()) missed some files. Correct
this and fully drop this macro, for which we should be using cmpxchg
like calls.

Cc: Steven Miao <realmz6@gmail.com>
Cc: Aurelien Jacquiot <a-jacquiot@ti.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Chris Metcalf <cmetcalf@ezchip.com>
Signed-off-by: Davidlohr Bueso <dbueso@suse.de>
---
 arch/blackfin/include/asm/cmpxchg.h | 1 -
 arch/c6x/include/asm/cmpxchg.h      | 2 --
 arch/frv/include/asm/cmpxchg.h      | 2 --
 arch/tile/include/asm/cmpxchg.h     | 2 --
 4 files changed, 7 deletions(-)

diff --git a/arch/blackfin/include/asm/cmpxchg.h b/arch/blackfin/include/asm/cmpxchg.h
index c05868c..2539288 100644
--- a/arch/blackfin/include/asm/cmpxchg.h
+++ b/arch/blackfin/include/asm/cmpxchg.h
@@ -128,6 +128,5 @@ static inline unsigned long __xchg(unsigned long x, volatile void *ptr,
 #endif /* !CONFIG_SMP */
 
 #define xchg(ptr, x) ((__typeof__(*(ptr)))__xchg((unsigned long)(x), (ptr), sizeof(*(ptr))))
-#define tas(ptr) ((void)xchg((ptr), 1))
 
 #endif /* __ARCH_BLACKFIN_CMPXCHG__ */
diff --git a/arch/c6x/include/asm/cmpxchg.h b/arch/c6x/include/asm/cmpxchg.h
index b27c8ce..93d0a5a 100644
--- a/arch/c6x/include/asm/cmpxchg.h
+++ b/arch/c6x/include/asm/cmpxchg.h
@@ -47,8 +47,6 @@ static inline unsigned int __xchg(unsigned int x, volatile void *ptr, int size)
 #define xchg(ptr, x) \
 	((__typeof__(*(ptr)))__xchg((unsigned int)(x), (void *) (ptr), \
 				    sizeof(*(ptr))))
-#define tas(ptr)    xchg((ptr), 1)
-
 
 #include <asm-generic/cmpxchg-local.h>
 
diff --git a/arch/frv/include/asm/cmpxchg.h b/arch/frv/include/asm/cmpxchg.h
index 5b04dd0..a899765 100644
--- a/arch/frv/include/asm/cmpxchg.h
+++ b/arch/frv/include/asm/cmpxchg.h
@@ -69,8 +69,6 @@ extern uint32_t __xchg_32(uint32_t i, volatile void *v);
 
 #endif
 
-#define tas(ptr) (xchg((ptr), 1))
-
 /*****************************************************************************/
 /*
  * compare and conditionally exchange value with memory
diff --git a/arch/tile/include/asm/cmpxchg.h b/arch/tile/include/asm/cmpxchg.h
index 0ccda3c..25d5899 100644
--- a/arch/tile/include/asm/cmpxchg.h
+++ b/arch/tile/include/asm/cmpxchg.h
@@ -127,8 +127,6 @@ long long _atomic64_cmpxchg(long long *v, long long o, long long n);
 
 #endif
 
-#define tas(ptr) xchg((ptr), 1)
-
 #endif /* __ASSEMBLY__ */
 
 #endif /* _ASM_TILE_CMPXCHG_H */
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH -tip 0/4] A few updates around smp_store_mb() Davidlohr Bueso <dave@stgolabs.net> - 2015-10-27 21:00 +0100
  [PATCH 2/4] arch,barrier: Use smp barriers in smp_store_release() Davidlohr Bueso <dave@stgolabs.net> - 2015-10-27 21:00 +0100
    Re: [PATCH 2/4] arch,barrier: Use smp barriers in smp_store_release() Davidlohr Bueso <dave@stgolabs.net> - 2015-10-27 21:10 +0100
  [PATCH 1/4] arch,cmpxchg: Remove tas() definitions Davidlohr Bueso <dave@stgolabs.net> - 2015-10-27 21:00 +0100
    Re: [PATCH 1/4] arch,cmpxchg: Remove tas() definitions David Howells <dhowells@redhat.com> - 2015-10-28 00:30 +0100

csiph-web