diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c index 8c3fef1db09ccb03507a89de6cbd7971dd803f41..ce89ffb474d0cbeba8b2d84af5c3a6c9ae5f7389 100644 --- a/kernel/time/tick-sched.c +++ b/kernel/time/tick-sched.c @@ -570,7 +570,7 @@ void tick_setup_sched_timer(void) /* Get the next period (per cpu) */ ts->sched_timer.expires = tick_init_jiffy_update(); offset = ktime_to_ns(tick_period) >> 1; - do_div(offset, NR_CPUS); + do_div(offset, num_possible_cpus()); offset *= smp_processor_id(); ts->sched_timer.expires = ktime_add_ns(ts->sched_timer.expires, offset);