Commit 0c1fa030 authored by Vincent Guittot's avatar Vincent Guittot Committed by Alistair Delva
Browse files

FROMLIST: sched/fair: fix find_idlest_group() to handle CPU affinity



Because of CPU affinity, the local group can be skipped which breaks the
assumption that statistics are always collected for local group. With
uninitialized local_sgs, the comparison is meaningless and the behavior
unpredictable. This can even end up to use local pointer which is to
NULL in this case.

If the local group has been skipped because of CPU affinity, we return
the idlest group.

Fixes: 57abff06 ("sched/fair: Rework find_idlest_group()")
Reported-by: default avatarJohn Stultz <john.stultz@linaro.org>
Signed-off-by: default avatarVincent Guittot <vincent.guittot@linaro.org>
Tested-by: default avatarJohn Stultz <john.stultz@linaro.org>
Link: https://lkml.org/lkml/2019/12/4/1042


Signed-off-by: default avatarJohn Stultz <john.stultz@linaro.org>
Change-Id: Ica9738112b1ee9c485e0354a37f4ce887c983531
parent cdf0b192
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment