]> git.baikalelectronics.ru Git - kernel.git/commit
sched: Update effective_load() to use global share weights
authorPaul Turner <pjt@google.com>
Sat, 15 Jan 2011 01:57:50 +0000 (17:57 -0800)
committerIngo Molnar <mingo@elte.hu>
Tue, 18 Jan 2011 14:09:38 +0000 (15:09 +0100)
commit9c35ac5d07748184d20939a45ac1f47199d21d07
tree77d40bcc72c1590dfcaeadb60e92a270bd204c52
parent63d54b48049b3b64d28a6ee75e19c02dc84afa7b
sched: Update effective_load() to use global share weights

Previously effective_load would approximate the global load weight present on
a group taking advantage of:

entity_weight = tg->shares ( lw / global_lw ), where entity_weight was provided
by tg_shares_up.

This worked (approximately) for an 'empty' (at tg level) cpu since we would
place boost load representative of what a newly woken task would receive.

However, now that load is instantaneously updated this assumption is no longer
true and the load calculation is rather incorrect in this case.

Fix this (and improve the general case) by re-writing effective_load to take
advantage of the new shares distribution code.

Signed-off-by: Paul Turner <pjt@google.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <20110115015817.069769529@google.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/sched_fair.c