aboutsummaryrefslogtreecommitdiffstats
path: root/arch/parisc
diff options
context:
space:
mode:
authorArun Sharma <asharma@fb.com>2011-07-26 19:09:06 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-07-26 19:49:47 -0400
commit60063497a95e716c9a689af3be2687d261f115b4 (patch)
tree6ce0d68db76982c53df46aee5f29f944ebf2c320 /arch/parisc
parent148817ba092f9f6edd35bad3c6c6b8e8f90fe2ed (diff)
atomic: use <linux/atomic.h>
This allows us to move duplicated code in <asm/atomic.h> (atomic_inc_not_zero() for now) to <linux/atomic.h> Signed-off-by: Arun Sharma <asharma@fb.com> Reviewed-by: Eric Dumazet <eric.dumazet@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: David Miller <davem@davemloft.net> Cc: Eric Dumazet <eric.dumazet@gmail.com> Acked-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/parisc')
-rw-r--r--arch/parisc/include/asm/atomic.h1
-rw-r--r--arch/parisc/include/asm/bitops.h2
-rw-r--r--arch/parisc/include/asm/mmu_context.h2
-rw-r--r--arch/parisc/kernel/parisc_ksyms.c2
-rw-r--r--arch/parisc/kernel/smp.c2
-rw-r--r--arch/parisc/kernel/traps.c2
-rw-r--r--arch/parisc/lib/bitops.c2
7 files changed, 6 insertions, 7 deletions
diff --git a/arch/parisc/include/asm/atomic.h b/arch/parisc/include/asm/atomic.h
index f81955934aeb..192488999b63 100644
--- a/arch/parisc/include/asm/atomic.h
+++ b/arch/parisc/include/asm/atomic.h
@@ -220,7 +220,6 @@ static __inline__ int atomic_add_unless(atomic_t *v, int a, int u)
220 return c != (u); 220 return c != (u);
221} 221}
222 222
223#define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0)
224 223
225#define atomic_add(i,v) ((void)(__atomic_add_return( (i),(v)))) 224#define atomic_add(i,v) ((void)(__atomic_add_return( (i),(v))))
226#define atomic_sub(i,v) ((void)(__atomic_add_return(-(i),(v)))) 225#define atomic_sub(i,v) ((void)(__atomic_add_return(-(i),(v))))
diff --git a/arch/parisc/include/asm/bitops.h b/arch/parisc/include/asm/bitops.h
index 4e833aa05a44..8c9b631d2a78 100644
--- a/arch/parisc/include/asm/bitops.h
+++ b/arch/parisc/include/asm/bitops.h
@@ -8,7 +8,7 @@
8#include <linux/compiler.h> 8#include <linux/compiler.h>
9#include <asm/types.h> /* for BITS_PER_LONG/SHIFT_PER_LONG */ 9#include <asm/types.h> /* for BITS_PER_LONG/SHIFT_PER_LONG */
10#include <asm/byteorder.h> 10#include <asm/byteorder.h>
11#include <asm/atomic.h> 11#include <linux/atomic.h>
12 12
13/* 13/*
14 * HP-PARISC specific bit operations 14 * HP-PARISC specific bit operations
diff --git a/arch/parisc/include/asm/mmu_context.h b/arch/parisc/include/asm/mmu_context.h
index 354b2aca990e..59be25764433 100644
--- a/arch/parisc/include/asm/mmu_context.h
+++ b/arch/parisc/include/asm/mmu_context.h
@@ -3,7 +3,7 @@
3 3
4#include <linux/mm.h> 4#include <linux/mm.h>
5#include <linux/sched.h> 5#include <linux/sched.h>
6#include <asm/atomic.h> 6#include <linux/atomic.h>
7#include <asm/pgalloc.h> 7#include <asm/pgalloc.h>
8#include <asm/pgtable.h> 8#include <asm/pgtable.h>
9#include <asm-generic/mm_hooks.h> 9#include <asm-generic/mm_hooks.h>
diff --git a/arch/parisc/kernel/parisc_ksyms.c b/arch/parisc/kernel/parisc_ksyms.c
index df653663d3db..a7bb757a5497 100644
--- a/arch/parisc/kernel/parisc_ksyms.c
+++ b/arch/parisc/kernel/parisc_ksyms.c
@@ -31,7 +31,7 @@
31#include <linux/string.h> 31#include <linux/string.h>
32EXPORT_SYMBOL(memset); 32EXPORT_SYMBOL(memset);
33 33
34#include <asm/atomic.h> 34#include <linux/atomic.h>
35EXPORT_SYMBOL(__xchg8); 35EXPORT_SYMBOL(__xchg8);
36EXPORT_SYMBOL(__xchg32); 36EXPORT_SYMBOL(__xchg32);
37EXPORT_SYMBOL(__cmpxchg_u32); 37EXPORT_SYMBOL(__cmpxchg_u32);
diff --git a/arch/parisc/kernel/smp.c b/arch/parisc/kernel/smp.c
index 828305f19cff..32d588488f04 100644
--- a/arch/parisc/kernel/smp.c
+++ b/arch/parisc/kernel/smp.c
@@ -33,7 +33,7 @@
33#include <linux/ftrace.h> 33#include <linux/ftrace.h>
34 34
35#include <asm/system.h> 35#include <asm/system.h>
36#include <asm/atomic.h> 36#include <linux/atomic.h>
37#include <asm/current.h> 37#include <asm/current.h>
38#include <asm/delay.h> 38#include <asm/delay.h>
39#include <asm/tlbflush.h> 39#include <asm/tlbflush.h>
diff --git a/arch/parisc/kernel/traps.c b/arch/parisc/kernel/traps.c
index 8b58bf0b7d5a..f19e6604026a 100644
--- a/arch/parisc/kernel/traps.c
+++ b/arch/parisc/kernel/traps.c
@@ -33,7 +33,7 @@
33#include <asm/irq.h> 33#include <asm/irq.h>
34#include <asm/traps.h> 34#include <asm/traps.h>
35#include <asm/unaligned.h> 35#include <asm/unaligned.h>
36#include <asm/atomic.h> 36#include <linux/atomic.h>
37#include <asm/smp.h> 37#include <asm/smp.h>
38#include <asm/pdc.h> 38#include <asm/pdc.h>
39#include <asm/pdc_chassis.h> 39#include <asm/pdc_chassis.h>
diff --git a/arch/parisc/lib/bitops.c b/arch/parisc/lib/bitops.c
index 353963d42059..a8bffd8af77d 100644
--- a/arch/parisc/lib/bitops.c
+++ b/arch/parisc/lib/bitops.c
@@ -9,7 +9,7 @@
9#include <linux/kernel.h> 9#include <linux/kernel.h>
10#include <linux/spinlock.h> 10#include <linux/spinlock.h>
11#include <asm/system.h> 11#include <asm/system.h>
12#include <asm/atomic.h> 12#include <linux/atomic.h>
13 13
14#ifdef CONFIG_SMP 14#ifdef CONFIG_SMP
15arch_spinlock_t __atomic_hash[ATOMIC_HASH_SIZE] __lock_aligned = { 15arch_spinlock_t __atomic_hash[ATOMIC_HASH_SIZE] __lock_aligned = {