Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
[pandora-kernel.git] / arch / mips / kernel / smp-up.c
1 /*
2  * This file is subject to the terms and conditions of the GNU General Public
3  * License.  See the file "COPYING" in the main directory of this archive
4  * for more details.
5  *
6  * Copyright (C) 2006, 07 by Ralf Baechle (ralf@linux-mips.org)
7  *
8  * Symmetric Uniprocessor (TM) Support
9  */
10 #include <linux/kernel.h>
11 #include <linux/sched.h>
12
13 /*
14  * Send inter-processor interrupt
15  */
16 static void up_send_ipi_single(int cpu, unsigned int action)
17 {
18         panic(KERN_ERR "%s called", __func__);
19 }
20
21 static inline void up_send_ipi_mask(cpumask_t mask, unsigned int action)
22 {
23         panic(KERN_ERR "%s called", __func__);
24 }
25
26 /*
27  *  After we've done initial boot, this function is called to allow the
28  *  board code to clean up state, if needed
29  */
30 static void __cpuinit up_init_secondary(void)
31 {
32 }
33
34 static void __cpuinit up_smp_finish(void)
35 {
36 }
37
38 /* Hook for after all CPUs are online */
39 static void up_cpus_done(void)
40 {
41 }
42
43 /*
44  * Firmware CPU startup hook
45  */
46 static void __cpuinit up_boot_secondary(int cpu, struct task_struct *idle)
47 {
48 }
49
50 static void __init up_smp_setup(void)
51 {
52 }
53
54 static void __init up_prepare_cpus(unsigned int max_cpus)
55 {
56 }
57
58 #ifdef CONFIG_HOTPLUG_CPU
59 static int up_cpu_disable(void)
60 {
61         return -ENOSYS;
62 }
63
64 static void up_cpu_die(unsigned int cpu)
65 {
66         BUG();
67 }
68 #endif
69
70 struct plat_smp_ops up_smp_ops = {
71         .send_ipi_single        = up_send_ipi_single,
72         .send_ipi_mask          = up_send_ipi_mask,
73         .init_secondary         = up_init_secondary,
74         .smp_finish             = up_smp_finish,
75         .cpus_done              = up_cpus_done,
76         .boot_secondary         = up_boot_secondary,
77         .smp_setup              = up_smp_setup,
78         .prepare_cpus           = up_prepare_cpus,
79 #ifdef CONFIG_HOTPLUG_CPU
80         .cpu_disable            = up_cpu_disable,
81         .cpu_die                = up_cpu_die,
82 #endif
83 };