diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-02-19 19:04:55 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-02-19 19:04:55 -0800 |
| commit | bcbd818c069b9e1bf82517401225b152a33968e2 (patch) | |
| tree | 3fcdcf02b15fdd77998589a6158d0e36ba137d1c /kernel/smpboot.c | |
| parent | d652e1eb8e7b739fccbfb503a3da3e9f640fbf3d (diff) | |
| parent | 14e568e78f6f80ca1e27256641ddf524c7dbdc51 (diff) | |
| download | olio-linux-3.10-bcbd818c069b9e1bf82517401225b152a33968e2.tar.xz olio-linux-3.10-bcbd818c069b9e1bf82517401225b152a33968e2.zip | |
Merge branch 'smp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull preparatory smp/hotplug patches from Ingo Molnar:
"Some early preparatory changes for the WIP hotplug rework by Thomas
Gleixner."
* 'smp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
stop_machine: Use smpboot threads
stop_machine: Store task reference in a separate per cpu variable
smpboot: Allow selfparking per cpu threads
Diffstat (limited to 'kernel/smpboot.c')
| -rw-r--r-- | kernel/smpboot.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/kernel/smpboot.c b/kernel/smpboot.c index d6c5fc05424..d4abac26177 100644 --- a/kernel/smpboot.c +++ b/kernel/smpboot.c @@ -183,9 +183,10 @@ __smpboot_create_thread(struct smp_hotplug_thread *ht, unsigned int cpu) kfree(td); return PTR_ERR(tsk); } - get_task_struct(tsk); *per_cpu_ptr(ht->store, cpu) = tsk; + if (ht->create) + ht->create(cpu); return 0; } @@ -225,7 +226,7 @@ static void smpboot_park_thread(struct smp_hotplug_thread *ht, unsigned int cpu) { struct task_struct *tsk = *per_cpu_ptr(ht->store, cpu); - if (tsk) + if (tsk && !ht->selfparking) kthread_park(tsk); } |