summaryrefslogtreecommitdiffstats
path: root/kernel/smp.c
diff options
context:
space:
mode:
authorPeter Zijlstra <peterz@infradead.org>2017-05-19 12:58:25 +0200
committerIngo Molnar <mingo@kernel.org>2017-05-23 10:01:32 +0200
commit6c8557bdb28df3ae97476c5e2aed6373cd235aab (patch)
tree2b134869f2f58494ac3ae664cf6403cb4ff2cbff /kernel/smp.c
parent3fc5b3b6a80b2e08a0fec0056208c5dff757e547 (diff)
downloadlinux-6c8557bdb28df3ae97476c5e2aed6373cd235aab.tar.bz2
smp, cpumask: Use non-atomic cpumask_{set,clear}_cpu()
The cpumasks in smp_call_function_many() are private and not subject to concurrency, atomic bitops are pointless and expensive. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> 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/smp.c')
-rw-r--r--kernel/smp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/smp.c b/kernel/smp.c
index 76d16fe3c427..3061483cb3ad 100644
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@ -436,7 +436,7 @@ void smp_call_function_many(const struct cpumask *mask,
cfd = this_cpu_ptr(&cfd_data);
cpumask_and(cfd->cpumask, mask, cpu_online_mask);
- cpumask_clear_cpu(this_cpu, cfd->cpumask);
+ __cpumask_clear_cpu(this_cpu, cfd->cpumask);
/* Some callers race with other cpus changing the passed mask */
if (unlikely(!cpumask_weight(cfd->cpumask)))
@@ -452,7 +452,7 @@ void smp_call_function_many(const struct cpumask *mask,
csd->func = func;
csd->info = info;
if (llist_add(&csd->llist, &per_cpu(call_single_queue, cpu)))
- cpumask_set_cpu(cpu, cfd->cpumask_ipi);
+ __cpumask_set_cpu(cpu, cfd->cpumask_ipi);
}
/* Send a message to all CPUs in the map */