diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2013-03-27 11:44:00 -0400 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2013-06-10 16:45:49 -0400 |
commit | 127781d1ba1ee5bbe1780afa35dd0e71583b143d (patch) | |
tree | 3c9b5961bc02e7f380a7bd7932181329ecbec397 /include/linux | |
parent | efc151c33b971148894789dc7c5589dec46d4348 (diff) |
rcu: Remove TINY_PREEMPT_RCU
TINY_PREEMPT_RCU adds significant code and complexity, but does not
offer commensurate benefits. People currently using TINY_PREEMPT_RCU
can get much better memory footprint with TINY_RCU, or, if they really
need preemptible RCU, they can use TREE_PREEMPT_RCU with a relatively
minor degradation in memory footprint. Please note that this move
has been widely publicized on LKML (https://lkml.org/lkml/2012/11/12/545)
and on LWN (http://lwn.net/Articles/541037/).
This commit therefore removes TINY_PREEMPT_RCU.
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
[ paulmck: Updated to eliminate #else in rcutiny.h as suggested by Josh ]
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/hardirq.h | 2 | ||||
-rw-r--r-- | include/linux/rcupdate.h | 2 | ||||
-rw-r--r-- | include/linux/rcutiny.h | 24 |
3 files changed, 4 insertions, 24 deletions
diff --git a/include/linux/hardirq.h b/include/linux/hardirq.h index c1d6555d2567..05bcc0903766 100644 --- a/include/linux/hardirq.h +++ b/include/linux/hardirq.h | |||
@@ -128,7 +128,7 @@ extern void synchronize_irq(unsigned int irq); | |||
128 | # define synchronize_irq(irq) barrier() | 128 | # define synchronize_irq(irq) barrier() |
129 | #endif | 129 | #endif |
130 | 130 | ||
131 | #if defined(CONFIG_TINY_RCU) || defined(CONFIG_TINY_PREEMPT_RCU) | 131 | #if defined(CONFIG_TINY_RCU) |
132 | 132 | ||
133 | static inline void rcu_nmi_enter(void) | 133 | static inline void rcu_nmi_enter(void) |
134 | { | 134 | { |
diff --git a/include/linux/rcupdate.h b/include/linux/rcupdate.h index ddcc7826d907..70b1522badd3 100644 --- a/include/linux/rcupdate.h +++ b/include/linux/rcupdate.h | |||
@@ -277,7 +277,7 @@ void wait_rcu_gp(call_rcu_func_t crf); | |||
277 | 277 | ||
278 | #if defined(CONFIG_TREE_RCU) || defined(CONFIG_TREE_PREEMPT_RCU) | 278 | #if defined(CONFIG_TREE_RCU) || defined(CONFIG_TREE_PREEMPT_RCU) |
279 | #include <linux/rcutree.h> | 279 | #include <linux/rcutree.h> |
280 | #elif defined(CONFIG_TINY_RCU) || defined(CONFIG_TINY_PREEMPT_RCU) | 280 | #elif defined(CONFIG_TINY_RCU) |
281 | #include <linux/rcutiny.h> | 281 | #include <linux/rcutiny.h> |
282 | #else | 282 | #else |
283 | #error "Unknown RCU implementation specified to kernel configuration" | 283 | #error "Unknown RCU implementation specified to kernel configuration" |
diff --git a/include/linux/rcutiny.h b/include/linux/rcutiny.h index 4e56a9c69a35..d3c094ffa960 100644 --- a/include/linux/rcutiny.h +++ b/include/linux/rcutiny.h | |||
@@ -53,16 +53,7 @@ static inline void rcu_barrier(void) | |||
53 | rcu_barrier_sched(); /* Only one CPU, so only one list of callbacks! */ | 53 | rcu_barrier_sched(); /* Only one CPU, so only one list of callbacks! */ |
54 | } | 54 | } |
55 | 55 | ||
56 | #else /* #ifdef CONFIG_TINY_RCU */ | 56 | #endif /* #ifdef CONFIG_TINY_RCU */ |
57 | |||
58 | void synchronize_rcu_expedited(void); | ||
59 | |||
60 | static inline void rcu_barrier(void) | ||
61 | { | ||
62 | wait_rcu_gp(call_rcu); | ||
63 | } | ||
64 | |||
65 | #endif /* #else #ifdef CONFIG_TINY_RCU */ | ||
66 | 57 | ||
67 | static inline void synchronize_rcu_bh(void) | 58 | static inline void synchronize_rcu_bh(void) |
68 | { | 59 | { |
@@ -97,18 +88,7 @@ static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) | |||
97 | return 0; | 88 | return 0; |
98 | } | 89 | } |
99 | 90 | ||
100 | #else /* #ifdef CONFIG_TINY_RCU */ | 91 | #endif /* #ifdef CONFIG_TINY_RCU */ |
101 | |||
102 | void rcu_preempt_note_context_switch(void); | ||
103 | int rcu_preempt_needs_cpu(void); | ||
104 | |||
105 | static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) | ||
106 | { | ||
107 | *delta_jiffies = ULONG_MAX; | ||
108 | return rcu_preempt_needs_cpu(); | ||
109 | } | ||
110 | |||
111 | #endif /* #else #ifdef CONFIG_TINY_RCU */ | ||
112 | 92 | ||
113 | static inline void rcu_note_context_switch(int cpu) | 93 | static inline void rcu_note_context_switch(int cpu) |
114 | { | 94 | { |