Commit [74f518]  Maximize  Restore  History

sched: Cure load average vs NO_HZ woes

Chase reported that due to us decrementing calc_load_task prematurely
(before the next LOAD_FREQ sample), the load average could be scewed
by as much as the number of CPUs in the machine.

This patch, based on Chase's patch, cures the problem by keeping the
delta of the CPU going into NO_HZ idle separately and folding that in
on the next LOAD_FREQ update.

This restores the balance and we get strict LOAD_FREQ period samples.

Signed-off-by: Peter Zijlstra <>
Acked-by: Chase Douglas <>
LKML-Reference: <1271934490.1776.343.camel@laptop>
Signed-off-by: Ingo Molnar <>

Peter Zijlstra Peter Zijlstra 2010-04-22

Ingo Molnar Ingo Molnar 2010-04-23

changed kernel/sched.c
changed kernel/sched_idletask.c
kernel/sched.c Diff Switch to side-by-side view
kernel/sched_idletask.c Diff Switch to side-by-side view

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks