diff options
author | David S. Miller <davem@sunset.davemloft.net> | 2007-07-14 03:58:53 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-07-16 07:04:58 -0400 |
commit | 27a2ef382c7935a4dd02bff9fd361ce118df98c6 (patch) | |
tree | 046a77f2b63e89222f44b536082e30c73a160e7f /arch/sparc64/kernel/smp.c | |
parent | 8f3fff205071dc1bd3203a0f6a5bf3b30e68e26f (diff) |
[SPARC64]: SMP build fixes.
With the move of ldom_startcpu_cpuid() into smp.c some other
things need to follow along:
1) smp.c is not a driver so we can't use "PFX" macro in the
printk calls.
2) smp.c now needs asm/io.h and asm/hvtramp.h, ds.c no longer
does
3) kimage_addr_to_ra() also needs to move into smp.c
While we're here, update copyright info and my email address
in smp.c
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64/kernel/smp.c')
-rw-r--r-- | arch/sparc64/kernel/smp.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/arch/sparc64/kernel/smp.c b/arch/sparc64/kernel/smp.c index 833b284616a4..9d02b3a9bb85 100644 --- a/arch/sparc64/kernel/smp.c +++ b/arch/sparc64/kernel/smp.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* smp.c: Sparc64 SMP support. | 1 | /* smp.c: Sparc64 SMP support. |
2 | * | 2 | * |
3 | * Copyright (C) 1997 David S. Miller (davem@caip.rutgers.edu) | 3 | * Copyright (C) 1997, 2007 David S. Miller (davem@davemloft.net) |
4 | */ | 4 | */ |
5 | 5 | ||
6 | #include <linux/module.h> | 6 | #include <linux/module.h> |
@@ -28,6 +28,8 @@ | |||
28 | #include <asm/tlbflush.h> | 28 | #include <asm/tlbflush.h> |
29 | #include <asm/mmu_context.h> | 29 | #include <asm/mmu_context.h> |
30 | #include <asm/cpudata.h> | 30 | #include <asm/cpudata.h> |
31 | #include <asm/hvtramp.h> | ||
32 | #include <asm/io.h> | ||
31 | 33 | ||
32 | #include <asm/irq.h> | 34 | #include <asm/irq.h> |
33 | #include <asm/irq_regs.h> | 35 | #include <asm/irq_regs.h> |
@@ -282,6 +284,14 @@ static void smp_synchronize_one_tick(int cpu) | |||
282 | } | 284 | } |
283 | 285 | ||
284 | #if defined(CONFIG_SUN_LDOMS) && defined(CONFIG_HOTPLUG_CPU) | 286 | #if defined(CONFIG_SUN_LDOMS) && defined(CONFIG_HOTPLUG_CPU) |
287 | /* XXX Put this in some common place. XXX */ | ||
288 | static unsigned long kimage_addr_to_ra(void *p) | ||
289 | { | ||
290 | unsigned long val = (unsigned long) p; | ||
291 | |||
292 | return kern_base + (val - KERNBASE); | ||
293 | } | ||
294 | |||
285 | static void ldom_startcpu_cpuid(unsigned int cpu, unsigned long thread_reg) | 295 | static void ldom_startcpu_cpuid(unsigned int cpu, unsigned long thread_reg) |
286 | { | 296 | { |
287 | extern unsigned long sparc64_ttable_tl0; | 297 | extern unsigned long sparc64_ttable_tl0; |
@@ -295,7 +305,7 @@ static void ldom_startcpu_cpuid(unsigned int cpu, unsigned long thread_reg) | |||
295 | 305 | ||
296 | hdesc = kzalloc(sizeof(*hdesc), GFP_KERNEL); | 306 | hdesc = kzalloc(sizeof(*hdesc), GFP_KERNEL); |
297 | if (!hdesc) { | 307 | if (!hdesc) { |
298 | printk(KERN_ERR PFX "ldom_startcpu_cpuid: Cannot allocate " | 308 | printk(KERN_ERR "ldom_startcpu_cpuid: Cannot allocate " |
299 | "hvtramp_descr.\n"); | 309 | "hvtramp_descr.\n"); |
300 | return; | 310 | return; |
301 | } | 311 | } |