Re: [PATCH] tick: shift tick_nohz_switch_to_nohz() from tick_check_oneshot_change() to hrtimer_run_queues()

From: Oleg Nesterov
Date: Thu May 30 2024 - 13:13:20 EST


On 05/30, Frederic Weisbecker wrote:
>
> > +extern int tick_check_oneshot_change(void);
> > +extern void tick_nohz_switch_to_nohz(void);
>
> tick_nohz_switch_to_nohz() is only built with CONFIG_NO_HZ_COMMON
>
> You will have a build issue with CONFIG_HIGH_RES_TIMER && !CONFIG_NO_HZ_COMMON

Hmm. I naively thought that a dummy definition below should be enough...

Thanks! I'll recheck and reply on Saturday.

Oleg.

> > #else /* !CONFIG_TICK_ONESHOT: */
> > static inline
> > @@ -124,7 +125,8 @@ static inline void tick_oneshot_notify(void) { }
> > static inline bool tick_oneshot_possible(void) { return false; }
> > static inline int tick_oneshot_mode_active(void) { return 0; }
> > static inline void tick_clock_notify(void) { }
> > -static inline int tick_check_oneshot_change(int allow_nohz) { return 0; }
> > +static inline int tick_check_oneshot_change(void) { return 0; }
> > +static inline void tick_nohz_switch_to_nohz(void) { }
> > #endif /* !CONFIG_TICK_ONESHOT */
>