mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
sched/core: Remove the tsk_cpus_allowed() wrapper
So the original intention of tsk_cpus_allowed() was to 'future-proof' the field - but it's pretty ineffectual at that, because half of the code uses ->cpus_allowed directly ... Also, the wrapper makes the code longer than the original expression! So just get rid of it. This also shrinks <linux/sched.h> a bit. Acked-by: Linus Torvalds <[email protected]> Cc: Mike Galbraith <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: [email protected] Signed-off-by: Ingo Molnar <[email protected]>
This commit is contained in:
parent
59ddbcb2f4
commit
0c98d344fe
16 changed files with 42 additions and 48 deletions
|
|
@ -234,7 +234,7 @@ static unsigned int us2e_freq_get(unsigned int cpu)
|
|||
cpumask_t cpus_allowed;
|
||||
unsigned long clock_tick, estar;
|
||||
|
||||
cpumask_copy(&cpus_allowed, tsk_cpus_allowed(current));
|
||||
cpumask_copy(&cpus_allowed, ¤t->cpus_allowed);
|
||||
set_cpus_allowed_ptr(current, cpumask_of(cpu));
|
||||
|
||||
clock_tick = sparc64_get_clock_tick(cpu) / 1000;
|
||||
|
|
@ -252,7 +252,7 @@ static int us2e_freq_target(struct cpufreq_policy *policy, unsigned int index)
|
|||
unsigned long clock_tick, divisor, old_divisor, estar;
|
||||
cpumask_t cpus_allowed;
|
||||
|
||||
cpumask_copy(&cpus_allowed, tsk_cpus_allowed(current));
|
||||
cpumask_copy(&cpus_allowed, ¤t->cpus_allowed);
|
||||
set_cpus_allowed_ptr(current, cpumask_of(cpu));
|
||||
|
||||
new_freq = clock_tick = sparc64_get_clock_tick(cpu) / 1000;
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ static unsigned int us3_freq_get(unsigned int cpu)
|
|||
unsigned long reg;
|
||||
unsigned int ret;
|
||||
|
||||
cpumask_copy(&cpus_allowed, tsk_cpus_allowed(current));
|
||||
cpumask_copy(&cpus_allowed, ¤t->cpus_allowed);
|
||||
set_cpus_allowed_ptr(current, cpumask_of(cpu));
|
||||
|
||||
reg = read_safari_cfg();
|
||||
|
|
@ -99,7 +99,7 @@ static int us3_freq_target(struct cpufreq_policy *policy, unsigned int index)
|
|||
unsigned long new_bits, new_freq, reg;
|
||||
cpumask_t cpus_allowed;
|
||||
|
||||
cpumask_copy(&cpus_allowed, tsk_cpus_allowed(current));
|
||||
cpumask_copy(&cpus_allowed, ¤t->cpus_allowed);
|
||||
set_cpus_allowed_ptr(current, cpumask_of(cpu));
|
||||
|
||||
new_freq = sparc64_get_clock_tick(cpu) / 1000;
|
||||
|
|
|
|||
Loading…
Reference in a new issue