aboutsummaryrefslogtreecommitdiffstats
path: root/arch/cris
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/cris
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/cris')
-rw-r--r--arch/cris/arch-v32/drivers/cryptocop.c2
-rw-r--r--arch/cris/arch-v32/kernel/smp.c2
-rw-r--r--arch/cris/include/asm/atomic.h1
-rw-r--r--arch/cris/include/asm/bitops.h2
-rw-r--r--arch/cris/kernel/process.c2
5 files changed, 4 insertions, 5 deletions
diff --git a/arch/cris/arch-v32/drivers/cryptocop.c b/arch/cris/arch-v32/drivers/cryptocop.c
index c03bc3bc30c2..642c6fed43d7 100644
--- a/arch/cris/arch-v32/drivers/cryptocop.c
+++ b/arch/cris/arch-v32/drivers/cryptocop.c
@@ -16,7 +16,7 @@
16 16
17#include <asm/uaccess.h> 17#include <asm/uaccess.h>
18#include <asm/io.h> 18#include <asm/io.h>
19#include <asm/atomic.h> 19#include <linux/atomic.h>
20 20
21#include <linux/list.h> 21#include <linux/list.h>
22#include <linux/interrupt.h> 22#include <linux/interrupt.h>
diff --git a/arch/cris/arch-v32/kernel/smp.c b/arch/cris/arch-v32/kernel/smp.c
index a0843a71aaee..0b99df72d2a4 100644
--- a/arch/cris/arch-v32/kernel/smp.c
+++ b/arch/cris/arch-v32/kernel/smp.c
@@ -7,7 +7,7 @@
7#include <asm/mmu_context.h> 7#include <asm/mmu_context.h>
8#include <hwregs/asm/mmu_defs_asm.h> 8#include <hwregs/asm/mmu_defs_asm.h>
9#include <hwregs/supp_reg.h> 9#include <hwregs/supp_reg.h>
10#include <asm/atomic.h> 10#include <linux/atomic.h>
11 11
12#include <linux/err.h> 12#include <linux/err.h>
13#include <linux/init.h> 13#include <linux/init.h>
diff --git a/arch/cris/include/asm/atomic.h b/arch/cris/include/asm/atomic.h
index 88dc9b9c4ba0..ce9f67e4d977 100644
--- a/arch/cris/include/asm/atomic.h
+++ b/arch/cris/include/asm/atomic.h
@@ -150,7 +150,6 @@ static inline int atomic_add_unless(atomic_t *v, int a, int u)
150 cris_atomic_restore(v, flags); 150 cris_atomic_restore(v, flags);
151 return ret != u; 151 return ret != u;
152} 152}
153#define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0)
154 153
155/* Atomic operations are already serializing */ 154/* Atomic operations are already serializing */
156#define smp_mb__before_atomic_dec() barrier() 155#define smp_mb__before_atomic_dec() barrier()
diff --git a/arch/cris/include/asm/bitops.h b/arch/cris/include/asm/bitops.h
index c0092fc7d846..a78a2d70cd8b 100644
--- a/arch/cris/include/asm/bitops.h
+++ b/arch/cris/include/asm/bitops.h
@@ -20,7 +20,7 @@
20 20
21#include <arch/bitops.h> 21#include <arch/bitops.h>
22#include <asm/system.h> 22#include <asm/system.h>
23#include <asm/atomic.h> 23#include <linux/atomic.h>
24#include <linux/compiler.h> 24#include <linux/compiler.h>
25 25
26/* 26/*
diff --git a/arch/cris/kernel/process.c b/arch/cris/kernel/process.c
index c99aeab7cef7..aa585e4e979e 100644
--- a/arch/cris/kernel/process.c
+++ b/arch/cris/kernel/process.c
@@ -12,7 +12,7 @@
12 * This file handles the architecture-dependent parts of process handling.. 12 * This file handles the architecture-dependent parts of process handling..
13 */ 13 */
14 14
15#include <asm/atomic.h> 15#include <linux/atomic.h>
16#include <asm/pgtable.h> 16#include <asm/pgtable.h>
17#include <asm/uaccess.h> 17#include <asm/uaccess.h>
18#include <asm/irq.h> 18#include <asm/irq.h>