summaryrefslogtreecommitdiff
path: root/kernel/cpu.c
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2011-07-17 17:35:29 (GMT)
committerScott Wood <scottwood@freescale.com>2014-05-14 18:38:16 (GMT)
commit00341ee7b76da430fcb63ccc5717991cb4a14bad (patch)
tree87ec27d11328fb20335fad39eceeabff563ca94b /kernel/cpu.c
parent0a30be4525a026dfe566c5ae15e2073a2855abe8 (diff)
downloadlinux-fsl-qoriq-00341ee7b76da430fcb63ccc5717991cb4a14bad.tar.xz
hotplug-use-migrate-disable.patch
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'kernel/cpu.c')
-rw-r--r--kernel/cpu.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/cpu.c b/kernel/cpu.c
index b9c39b5..ef0e472 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -400,14 +400,13 @@ static int __ref _cpu_down(unsigned int cpu, int tasks_frozen)
cpumask_andnot(cpumask, cpu_online_mask, cpumask_of(cpu));
set_cpus_allowed_ptr(current, cpumask);
free_cpumask_var(cpumask);
- preempt_disable();
+ migrate_disable();
mycpu = smp_processor_id();
if (mycpu == cpu) {
printk(KERN_ERR "Yuck! Still on unplug CPU\n!");
- preempt_enable();
+ migrate_enable();
return -EBUSY;
}
- preempt_enable();
err = __cpu_notify(CPU_DOWN_PREPARE | mod, hcpu, -1, &nr_calls);
if (err) {
@@ -458,6 +457,7 @@ static int __ref _cpu_down(unsigned int cpu, int tasks_frozen)
out_release:
cpu_unplug_done(cpu);
out_cancel:
+ migrate_enable();
cpu_hotplug_done();
if (!err)
cpu_notify_nofail(CPU_POST_DEAD | mod, hcpu);