sched/fair: Fix unnecessary increase of balance interval
authorVincent Guittot <vincent.guittot@linaro.org>
Fri, 14 Dec 2018 16:01:57 +0000 (17:01 +0100)
committerIngo Molnar <mingo@kernel.org>
Sun, 27 Jan 2019 11:29:37 +0000 (12:29 +0100)
commit46a745d905858c7f453b29cffe368ba214b106fb
treeb083061f4ad237fdf68dc9dafcea272ac78dbec4
parent4ad4e481bd02c80c4b9c64e563d16d1c4442ea13
sched/fair: Fix unnecessary increase of balance interval

In case of active balancing, we increase the balance interval to cover
pinned tasks cases not covered by all_pinned logic. Neverthless, the
active migration triggered by asym packing should be treated as the normal
unbalanced case and reset the interval to default value, otherwise active
migration for asym_packing can be easily delayed for hundreds of ms
because of this pinned task detection mechanism.

The same happens to other conditions tested in need_active_balance() like
misfit task and when the capacity of src_cpu is reduced compared to
dst_cpu (see comments in need_active_balance() for details).

Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: valentin.schneider@arm.com
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
kernel/sched/fair.c