aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/tick.h
diff options
context:
space:
mode:
authorFrederic Weisbecker <fweisbec@gmail.com>2013-08-07 16:28:01 -0400
committerFrederic Weisbecker <fweisbec@gmail.com>2013-12-02 14:39:30 -0500
commite8fcaa5c54e3b0371230e5d43a6f650c667da9c5 (patch)
tree966d06c71bc79809ca34675b023602aefc8e578d /include/linux/tick.h
parentdc1ccc48159d63eca5089e507c82c7d22ef60839 (diff)
nohz: Convert a few places to use local per cpu accesses
A few functions use remote per CPU access APIs when they deal with local values. Just do the right conversion to improve performance, code readability and debug checks. While at it, lets extend some of these function names with *_this_cpu() suffix in order to display their purpose more clearly. Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'include/linux/tick.h')
-rw-r--r--include/linux/tick.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/tick.h b/include/linux/tick.h
index 5128d33bbb39..a004f66a6cf0 100644
--- a/include/linux/tick.h
+++ b/include/linux/tick.h
@@ -104,7 +104,7 @@ extern struct cpumask *tick_get_broadcast_oneshot_mask(void);
104extern void tick_clock_notify(void); 104extern void tick_clock_notify(void);
105extern int tick_check_oneshot_change(int allow_nohz); 105extern int tick_check_oneshot_change(int allow_nohz);
106extern struct tick_sched *tick_get_tick_sched(int cpu); 106extern struct tick_sched *tick_get_tick_sched(int cpu);
107extern void tick_check_idle(int cpu); 107extern void tick_check_idle(void);
108extern int tick_oneshot_mode_active(void); 108extern int tick_oneshot_mode_active(void);
109# ifndef arch_needs_cpu 109# ifndef arch_needs_cpu
110# define arch_needs_cpu(cpu) (0) 110# define arch_needs_cpu(cpu) (0)
@@ -112,7 +112,7 @@ extern int tick_oneshot_mode_active(void);
112# else 112# else
113static inline void tick_clock_notify(void) { } 113static inline void tick_clock_notify(void) { }
114static inline int tick_check_oneshot_change(int allow_nohz) { return 0; } 114static inline int tick_check_oneshot_change(int allow_nohz) { return 0; }
115static inline void tick_check_idle(int cpu) { } 115static inline void tick_check_idle(void) { }
116static inline int tick_oneshot_mode_active(void) { return 0; } 116static inline int tick_oneshot_mode_active(void) { return 0; }
117# endif 117# endif
118 118
@@ -121,7 +121,7 @@ static inline void tick_init(void) { }
121static inline void tick_cancel_sched_timer(int cpu) { } 121static inline void tick_cancel_sched_timer(int cpu) { }
122static inline void tick_clock_notify(void) { } 122static inline void tick_clock_notify(void) { }
123static inline int tick_check_oneshot_change(int allow_nohz) { return 0; } 123static inline int tick_check_oneshot_change(int allow_nohz) { return 0; }
124static inline void tick_check_idle(int cpu) { } 124static inline void tick_check_idle(void) { }
125static inline int tick_oneshot_mode_active(void) { return 0; } 125static inline int tick_oneshot_mode_active(void) { return 0; }
126#endif /* !CONFIG_GENERIC_CLOCKEVENTS */ 126#endif /* !CONFIG_GENERIC_CLOCKEVENTS */
127 127