diff options
author | Kyle McMartin <kyle@mcmartin.ca> | 2009-04-01 21:43:14 -0400 |
---|---|---|
committer | Kyle McMartin <kyle@mcmartin.ca> | 2009-04-01 21:43:14 -0400 |
commit | 7cec2ef4a298605b010f1c80041de884e777ea67 (patch) | |
tree | ea0e947f07d8818a955e8d257aba92c47d92ba12 /arch/parisc/kernel/smp.c | |
parent | 91400ac365da35b18036b46bdda27ddbcee4a663 (diff) | |
parent | 9bc181d8d7cb6462de0c315e364780ad275f7c57 (diff) |
Merge branch 'rusty-cpumask-parisc' into parisc
Diffstat (limited to 'arch/parisc/kernel/smp.c')
-rw-r--r-- | arch/parisc/kernel/smp.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/arch/parisc/kernel/smp.c b/arch/parisc/kernel/smp.c index 8545f2e7a2c0..1fd0f0cec037 100644 --- a/arch/parisc/kernel/smp.c +++ b/arch/parisc/kernel/smp.c | |||
@@ -114,7 +114,7 @@ halt_processor(void) | |||
114 | { | 114 | { |
115 | /* REVISIT : redirect I/O Interrupts to another CPU? */ | 115 | /* REVISIT : redirect I/O Interrupts to another CPU? */ |
116 | /* REVISIT : does PM *know* this CPU isn't available? */ | 116 | /* REVISIT : does PM *know* this CPU isn't available? */ |
117 | cpu_clear(smp_processor_id(), cpu_online_map); | 117 | set_cpu_online(smp_processor_id(), false); |
118 | local_irq_disable(); | 118 | local_irq_disable(); |
119 | for (;;) | 119 | for (;;) |
120 | ; | 120 | ; |
@@ -215,11 +215,11 @@ ipi_send(int cpu, enum ipi_message_type op) | |||
215 | } | 215 | } |
216 | 216 | ||
217 | static void | 217 | static void |
218 | send_IPI_mask(cpumask_t mask, enum ipi_message_type op) | 218 | send_IPI_mask(const struct cpumask *mask, enum ipi_message_type op) |
219 | { | 219 | { |
220 | int cpu; | 220 | int cpu; |
221 | 221 | ||
222 | for_each_cpu_mask(cpu, mask) | 222 | for_each_cpu(cpu, mask) |
223 | ipi_send(cpu, op); | 223 | ipi_send(cpu, op); |
224 | } | 224 | } |
225 | 225 | ||
@@ -258,7 +258,7 @@ smp_send_all_nop(void) | |||
258 | send_IPI_allbutself(IPI_NOP); | 258 | send_IPI_allbutself(IPI_NOP); |
259 | } | 259 | } |
260 | 260 | ||
261 | void arch_send_call_function_ipi(cpumask_t mask) | 261 | void arch_send_call_function_ipi_mask(const struct cpumask *mask) |
262 | { | 262 | { |
263 | send_IPI_mask(mask, IPI_CALL_FUNC); | 263 | send_IPI_mask(mask, IPI_CALL_FUNC); |
264 | } | 264 | } |
@@ -297,13 +297,14 @@ smp_cpu_init(int cpunum) | |||
297 | mb(); | 297 | mb(); |
298 | 298 | ||
299 | /* Well, support 2.4 linux scheme as well. */ | 299 | /* Well, support 2.4 linux scheme as well. */ |
300 | if (cpu_test_and_set(cpunum, cpu_online_map)) | 300 | if (cpu_isset(cpunum, cpu_online_map)) |
301 | { | 301 | { |
302 | extern void machine_halt(void); /* arch/parisc.../process.c */ | 302 | extern void machine_halt(void); /* arch/parisc.../process.c */ |
303 | 303 | ||
304 | printk(KERN_CRIT "CPU#%d already initialized!\n", cpunum); | 304 | printk(KERN_CRIT "CPU#%d already initialized!\n", cpunum); |
305 | machine_halt(); | 305 | machine_halt(); |
306 | } | 306 | } |
307 | set_cpu_online(cpunum, true); | ||
307 | 308 | ||
308 | /* Initialise the idle task for this CPU */ | 309 | /* Initialise the idle task for this CPU */ |
309 | atomic_inc(&init_mm.mm_count); | 310 | atomic_inc(&init_mm.mm_count); |
@@ -425,8 +426,8 @@ void __init smp_prepare_boot_cpu(void) | |||
425 | /* Setup BSP mappings */ | 426 | /* Setup BSP mappings */ |
426 | printk(KERN_INFO "SMP: bootstrap CPU ID is %d\n", bootstrap_processor); | 427 | printk(KERN_INFO "SMP: bootstrap CPU ID is %d\n", bootstrap_processor); |
427 | 428 | ||
428 | cpu_set(bootstrap_processor, cpu_online_map); | 429 | set_cpu_online(bootstrap_processor, true); |
429 | cpu_set(bootstrap_processor, cpu_present_map); | 430 | set_cpu_present(bootstrap_processor, true); |
430 | } | 431 | } |
431 | 432 | ||
432 | 433 | ||
@@ -437,8 +438,7 @@ void __init smp_prepare_boot_cpu(void) | |||
437 | */ | 438 | */ |
438 | void __init smp_prepare_cpus(unsigned int max_cpus) | 439 | void __init smp_prepare_cpus(unsigned int max_cpus) |
439 | { | 440 | { |
440 | cpus_clear(cpu_present_map); | 441 | init_cpu_present(cpumask_of(0)); |
441 | cpu_set(0, cpu_present_map); | ||
442 | 442 | ||
443 | parisc_max_cpus = max_cpus; | 443 | parisc_max_cpus = max_cpus; |
444 | if (!max_cpus) | 444 | if (!max_cpus) |