* [patch 2.5.30] alpha: percpu update [7/10]
@ 2002-08-10 15:30 Ivan Kokshaysky
0 siblings, 0 replies; only message in thread
From: Ivan Kokshaysky @ 2002-08-10 15:30 UTC (permalink / raw)
To: Linus Torvalds, Richard Henderson; +Cc: linux-kernel
Generic per-cpu areas; wrappers for SMP boot process.
Ivan.
--- 2.5.30/include/asm-alpha/percpu.h Thu Jan 1 00:00:00 1970
+++ linux/include/asm-alpha/percpu.h Sat Aug 10 01:29:20 2002
@@ -0,0 +1,6 @@
+#ifndef __ALPHA_PERCPU_H
+#define __ALPHA_PERCPU_H
+
+#include <asm-generic/percpu.h>
+
+#endif /* __ALPHA_PERCPU_H */
--- 2.5.30/arch/alpha/vmlinux.lds.in Sun May 26 13:58:11 2002
+++ linux/arch/alpha/vmlinux.lds.in Sat Aug 10 01:29:20 2002
@@ -58,6 +58,11 @@ SECTIONS
__initcall_end = .;
}
+ . = ALIGN(64);
+ __per_cpu_start = .;
+ .data.percpu : { *(.data.percpu) }
+ __per_cpu_end = .;
+
/* The initial task and kernel stack */
.data.init_thread ALIGN(2*8192) : {
__init_end = .;
--- 2.5.30/arch/alpha/kernel/smp.c Sat Aug 10 01:24:08 2002
+++ linux/arch/alpha/kernel/smp.c Sat Aug 10 01:29:20 2002
@@ -441,7 +441,7 @@ fork_by_hand(void)
* Bring one cpu online.
*/
static int __init
-smp_boot_one_cpu(int cpuid, int cpunum)
+smp_boot_one_cpu(int cpuid)
{
struct task_struct *idle;
long timeout;
@@ -578,7 +578,7 @@ smp_boot_cpus(void)
if (((hwrpb_cpu_present_mask >> i) & 1) == 0)
continue;
- if (smp_boot_one_cpu(i, cpu_count))
+ if (smp_boot_one_cpu(i))
continue;
cpu_present_mask |= 1UL << i;
@@ -603,14 +603,22 @@ smp_boot_cpus(void)
smp_num_cpus = cpu_count;
}
-/*
- * Called by smp_init to release the blocking online cpus once they
- * are all started.
- */
void __init
-smp_commence(void)
+smp_prepare_cpus(unsigned int max_cpus)
+{
+ smp_boot_cpus();
+}
+
+int __devinit
+__cpu_up(unsigned int cpu)
+{
+ return cpu_online(cpu) ? 0 : -ENOSYS;
+}
+
+void __init
+smp_cpus_done(unsigned int max_cpus)
{
- /* smp_init sets smp_threads_ready -- that's enough. */
+ smp_threads_ready = 1;
mb();
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2002-08-10 15:27 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-08-10 15:30 [patch 2.5.30] alpha: percpu update [7/10] Ivan Kokshaysky
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®