Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 536e7d5d authored by Puja Gupta's avatar Puja Gupta
Browse files

sched/fair: prevent possible infinite loop in compute_energy()



There is a race between hotplug and energy_diff which might result
in endless loop in compute_energy. When this happens, the end
condition cannot be detected.

We can store how many CPUs we need to visit at the beginning, and
bail out of the energy calculation if we visit more cpus than expected.

Change-Id: I916205877d49021bb97aca6c90a192a82d122661
Signed-off-by: default avatarChris Redpath <chris.redpath@arm.com>
Git-commit: 8a174b4749d384865b60690cb33cf9f2dc490986
Git-repo: https://android.googlesource.com/kernel/common/


Signed-off-by: default avatarPuja Gupta <pujag@codeaurora.org>
parent 1ca632e9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment