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

Commit 0d656015 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "sched/fair: Consider others if target cpu overutilized"

parents 74e9868b c28f0390
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -6213,6 +6213,12 @@ static inline bool task_fits_max(struct task_struct *p, int cpu)
	return __task_fits(p, cpu, 0);
}

static inline bool cpu_check_overutil_condition(int cpu,
						unsigned long util)
{
	return (capacity_orig_of(cpu) * 1024) < (util * capacity_margin);
}

bool __cpu_overutilized(int cpu, int delta)
{
	return (capacity_orig_of(cpu) * 1024) <
@@ -7062,7 +7068,7 @@ static inline int find_best_target(struct task_struct *p, int *backup_cpu,
			 */
			min_capped_util = max(new_util, capacity_min_of(i));

			if (new_util > capacity_orig)
			if (cpu_check_overutil_condition(i, new_util))
				continue;

			/*