diff options
author | Ingo Molnar <mingo@kernel.org> | 2017-02-05 15:41:03 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2017-03-02 08:42:24 +0100 |
commit | 4b53a3412d6663214ce9c754eff9373a9cff9dee (patch) | |
tree | c7045cdf109bc5b114117b70a2b7bdee4adf4b3a /kernel/sched/core.c | |
parent | 0c98d344fe5c27f6e4bce42ac503e9e9a51c7d1d (diff) | |
download | lwn-4b53a3412d6663214ce9c754eff9373a9cff9dee.tar.gz lwn-4b53a3412d6663214ce9c754eff9373a9cff9dee.zip |
sched/core: Remove the tsk_nr_cpus_allowed() wrapper
tsk_nr_cpus_allowed() too is a pretty pointless wrapper that
is not used consistently and which makes the code both harder
to read and longer as well.
So remove it - this also shrinks <linux/sched.h> a bit.
Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/sched/core.c')
-rw-r--r-- | kernel/sched/core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/sched/core.c b/kernel/sched/core.c index ef5bbf760a08..2d51ec65dc73 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c @@ -1549,7 +1549,7 @@ int select_task_rq(struct task_struct *p, int cpu, int sd_flags, int wake_flags) { lockdep_assert_held(&p->pi_lock); - if (tsk_nr_cpus_allowed(p) > 1) + if (p->nr_cpus_allowed > 1) cpu = p->sched_class->select_task_rq(p, cpu, sd_flags, wake_flags); else cpu = cpumask_any(&p->cpus_allowed); |