mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-16 19:47:55 +00:00
sched/fair: Remove select_idle_smt()
In order to make the next patch more readable, and to quantify the actual effectiveness of this pass, start by removing it. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> Reviewed-by: Vincent Guittot <vincent.guittot@linaro.org> Link: https://lkml.kernel.org/r/20210125085909.4600-4-mgorman@techsingularity.net
This commit is contained in:
parent
ed3cd45f8c
commit
6cd56ef1df
1 changed files with 0 additions and 30 deletions
|
@ -6114,27 +6114,6 @@ static int select_idle_core(struct task_struct *p, struct sched_domain *sd, int
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* Scan the local SMT mask for idle CPUs.
|
|
||||||
*/
|
|
||||||
static int select_idle_smt(struct task_struct *p, struct sched_domain *sd, int target)
|
|
||||||
{
|
|
||||||
int cpu;
|
|
||||||
|
|
||||||
if (!static_branch_likely(&sched_smt_present))
|
|
||||||
return -1;
|
|
||||||
|
|
||||||
for_each_cpu(cpu, cpu_smt_mask(target)) {
|
|
||||||
if (!cpumask_test_cpu(cpu, p->cpus_ptr) ||
|
|
||||||
!cpumask_test_cpu(cpu, sched_domain_span(sd)))
|
|
||||||
continue;
|
|
||||||
if (available_idle_cpu(cpu) || sched_idle_cpu(cpu))
|
|
||||||
return cpu;
|
|
||||||
}
|
|
||||||
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#else /* CONFIG_SCHED_SMT */
|
#else /* CONFIG_SCHED_SMT */
|
||||||
|
|
||||||
static inline int select_idle_core(struct task_struct *p, struct sched_domain *sd, int target)
|
static inline int select_idle_core(struct task_struct *p, struct sched_domain *sd, int target)
|
||||||
|
@ -6142,11 +6121,6 @@ static inline int select_idle_core(struct task_struct *p, struct sched_domain *s
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline int select_idle_smt(struct task_struct *p, struct sched_domain *sd, int target)
|
|
||||||
{
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif /* CONFIG_SCHED_SMT */
|
#endif /* CONFIG_SCHED_SMT */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -6336,10 +6310,6 @@ static int select_idle_sibling(struct task_struct *p, int prev, int target)
|
||||||
if ((unsigned)i < nr_cpumask_bits)
|
if ((unsigned)i < nr_cpumask_bits)
|
||||||
return i;
|
return i;
|
||||||
|
|
||||||
i = select_idle_smt(p, sd, target);
|
|
||||||
if ((unsigned)i < nr_cpumask_bits)
|
|
||||||
return i;
|
|
||||||
|
|
||||||
return target;
|
return target;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue