diff options
author | Gautham R Shenoy <ego@in.ibm.com> | 2008-01-25 15:08:02 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-01-25 15:08:02 -0500 |
commit | 95402b3829010fe1e208f44e4a158ccade88969a (patch) | |
tree | 3b9895b47623b4673e3c11121980e5171af76bbe /kernel/cpu.c | |
parent | 86ef5c9a8edd78e6bf92879f32329d89b2d55b5a (diff) |
cpu-hotplug: replace per-subsystem mutexes with get_online_cpus()
This patch converts the known per-subsystem mutexes to get_online_cpus
put_online_cpus. It also eliminates the CPU_LOCK_ACQUIRE and
CPU_LOCK_RELEASE hotplug notification events.
Signed-off-by: Gautham R Shenoy <ego@in.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/cpu.c')
-rw-r--r-- | kernel/cpu.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/kernel/cpu.c b/kernel/cpu.c index b0c4152995f8..e0d3a4f56ecb 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c | |||
@@ -218,7 +218,6 @@ static int _cpu_down(unsigned int cpu, int tasks_frozen) | |||
218 | return -EINVAL; | 218 | return -EINVAL; |
219 | 219 | ||
220 | cpu_hotplug_begin(); | 220 | cpu_hotplug_begin(); |
221 | raw_notifier_call_chain(&cpu_chain, CPU_LOCK_ACQUIRE, hcpu); | ||
222 | err = __raw_notifier_call_chain(&cpu_chain, CPU_DOWN_PREPARE | mod, | 221 | err = __raw_notifier_call_chain(&cpu_chain, CPU_DOWN_PREPARE | mod, |
223 | hcpu, -1, &nr_calls); | 222 | hcpu, -1, &nr_calls); |
224 | if (err == NOTIFY_BAD) { | 223 | if (err == NOTIFY_BAD) { |
@@ -271,7 +270,6 @@ out_thread: | |||
271 | out_allowed: | 270 | out_allowed: |
272 | set_cpus_allowed(current, old_allowed); | 271 | set_cpus_allowed(current, old_allowed); |
273 | out_release: | 272 | out_release: |
274 | raw_notifier_call_chain(&cpu_chain, CPU_LOCK_RELEASE, hcpu); | ||
275 | cpu_hotplug_done(); | 273 | cpu_hotplug_done(); |
276 | return err; | 274 | return err; |
277 | } | 275 | } |
@@ -302,7 +300,6 @@ static int __cpuinit _cpu_up(unsigned int cpu, int tasks_frozen) | |||
302 | return -EINVAL; | 300 | return -EINVAL; |
303 | 301 | ||
304 | cpu_hotplug_begin(); | 302 | cpu_hotplug_begin(); |
305 | raw_notifier_call_chain(&cpu_chain, CPU_LOCK_ACQUIRE, hcpu); | ||
306 | ret = __raw_notifier_call_chain(&cpu_chain, CPU_UP_PREPARE | mod, hcpu, | 303 | ret = __raw_notifier_call_chain(&cpu_chain, CPU_UP_PREPARE | mod, hcpu, |
307 | -1, &nr_calls); | 304 | -1, &nr_calls); |
308 | if (ret == NOTIFY_BAD) { | 305 | if (ret == NOTIFY_BAD) { |
@@ -326,7 +323,6 @@ out_notify: | |||
326 | if (ret != 0) | 323 | if (ret != 0) |
327 | __raw_notifier_call_chain(&cpu_chain, | 324 | __raw_notifier_call_chain(&cpu_chain, |
328 | CPU_UP_CANCELED | mod, hcpu, nr_calls, NULL); | 325 | CPU_UP_CANCELED | mod, hcpu, nr_calls, NULL); |
329 | raw_notifier_call_chain(&cpu_chain, CPU_LOCK_RELEASE, hcpu); | ||
330 | cpu_hotplug_done(); | 326 | cpu_hotplug_done(); |
331 | 327 | ||
332 | return ret; | 328 | return ret; |