diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2013-11-17 22:27:16 -0500 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-02-17 19:03:09 -0500 |
commit | ffa83fb565fbc397cbafb4b71fd1cce276d4c3b6 (patch) | |
tree | c849b1ea3517d6853b7b4cd386a682187e314f09 /include/linux/rcutiny.h | |
parent | 2f33b512a5460578f6cf11d7b7867bed53157c7c (diff) |
rcu: Optimize rcu_needs_cpu() for RCU_NOCB_CPU_ALL
If CONFIG_RCU_NOCB_CPU_ALL=y, then rcu_needs_cpu() will always
return false, however, the current version nevertheless checks
for RCU callbacks. This commit therefore creates a static inline
implementation of rcu_needs_cpu() that unconditionally returns false
when CONFIG_RCU_NOCB_CPU_ALL=y.
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Diffstat (limited to 'include/linux/rcutiny.h')
-rw-r--r-- | include/linux/rcutiny.h | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/include/linux/rcutiny.h b/include/linux/rcutiny.h index 6f01771b571c..9524903487d0 100644 --- a/include/linux/rcutiny.h +++ b/include/linux/rcutiny.h | |||
@@ -68,12 +68,6 @@ static inline void kfree_call_rcu(struct rcu_head *head, | |||
68 | call_rcu(head, func); | 68 | call_rcu(head, func); |
69 | } | 69 | } |
70 | 70 | ||
71 | static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) | ||
72 | { | ||
73 | *delta_jiffies = ULONG_MAX; | ||
74 | return 0; | ||
75 | } | ||
76 | |||
77 | static inline void rcu_note_context_switch(int cpu) | 71 | static inline void rcu_note_context_switch(int cpu) |
78 | { | 72 | { |
79 | rcu_sched_qs(cpu); | 73 | rcu_sched_qs(cpu); |