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:John Stultz <john.stultz@linaro.org> Signed-off-by:
Vincent Guittot <vincent.guittot@linaro.org> Tested-by:
John Stultz <john.stultz@linaro.org> Link: https://lkml.org/lkml/2019/12/4/1042 Signed-off-by:
John Stultz <john.stultz@linaro.org> Change-Id: Ica9738112b1ee9c485e0354a37f4ce887c983531
Loading
Please sign in to comment