]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
atomic-implement-generic-atomic_dec_if_positive-fix
authorAndrew Morton <akpm@linux-foundation.org>
Wed, 26 Sep 2012 01:33:46 +0000 (11:33 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 27 Sep 2012 07:26:41 +0000 (17:26 +1000)
do the "#define foo foo" trick in the conventional manner

Cc: "David S. Miller" <davem@davemloft.net>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Michal Simek <monstr@monstr.eu>
Cc: Rik van Riel <riel@redhat.com>
Cc: Shaohua Li <shli@fusionio.com>
Cc: Shaohua Li <shli@kernel.org>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/microblaze/include/asm/atomic.h
arch/powerpc/include/asm/atomic.h

index d31a413ad0f0a64053febcc559003fccd89f323c..42ac382a09daf3109fbcad4a2f7ba96ffd1a8de5 100644 (file)
@@ -9,7 +9,7 @@
  * Atomically test *v and decrement if it is greater than 0.
  * The function returns the old value of *v minus 1.
  */
-static inline int __atomic_dec_if_positive(atomic_t *v)
+static inline int atomic_dec_if_positive(atomic_t *v)
 {
        unsigned long flags;
        int res;
@@ -22,6 +22,6 @@ static inline int __atomic_dec_if_positive(atomic_t *v)
 
        return res;
 }
-#define atomic_dec_if_positive __atomic_dec_if_positive
+#define atomic_dec_if_positive atomic_dec_if_positive
 
 #endif /* _ASM_MICROBLAZE_ATOMIC_H */
index d34ecbe5097b40471201a398849db24c40a2455b..e3b1d41c89be73425595b364370c096206a6a843 100644 (file)
@@ -247,7 +247,7 @@ static __inline__ int atomic_inc_not_zero(atomic_t *v)
  * The function returns the old value of *v minus 1, even if
  * the atomic variable, v, was not decremented.
  */
-static __inline__ int __atomic_dec_if_positive(atomic_t *v)
+static __inline__ int atomic_dec_if_positive(atomic_t *v)
 {
        int t;
 
@@ -268,7 +268,7 @@ static __inline__ int __atomic_dec_if_positive(atomic_t *v)
 
        return t;
 }
-#define atomic_dec_if_positive __atomic_dec_if_positive
+#define atomic_dec_if_positive atomic_dec_if_positive
 
 #define smp_mb__before_atomic_dec()     smp_mb()
 #define smp_mb__after_atomic_dec()      smp_mb()