On Tue, Apr 18, 2017 at 01:11:10PM +0200, Thomas Gleixner wrote: > +#ifdef CONFIG_SMP > +static u64 > +tick_tmigr_idle(struct tick_sched *ts, u64 next_global, u64 next_local) > +{ > + ts->tmigr_idle = 1; > + > + /* > + * If next_global is after next_local, event does not have to > + * be queued in the timer migration hierarchy, but cpu needs > + * to be marked as idle. > + */ > + if (next_global >= next_local) > + next_global = KTIME_MAX; > + > + next_global = tmigr_cpu_idle(next_global); > + > + return min_t(u64, next_local, next_global); > +} > + > +static void tick_tmigr_stop_idle(struct tick_sched *ts) > +{ > + if (ts->tmigr_idle) { > + ts->tmigr_idle = 0; > + tmigr_cpu_activate(); > + } > +} > +#else > +static u64 > +tick_tmigr_idle(struct tick_sched *ts, u64 next_global, u64 next_local) > +{ > + return min_t(u64, next_global, next_local); > +} > +static inline void tick_tmigr_stop_idle(struct tick_sched *ts) { } > +#endif /*CONFIG_SMP*/
Naming seems inconsistent with the rest of the file; s/tick_tmigr_idle/tick_tmigr_idle_enter/ s/tick_tmigr_stop_idle/tick_tmigr_idle_exit/ Or something would fit better.