aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-shmobile/hotplug.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-shmobile/hotplug.c')
-rw-r--r--arch/arm/mach-shmobile/hotplug.c41
1 files changed, 41 insertions, 0 deletions
diff --git a/arch/arm/mach-shmobile/hotplug.c b/arch/arm/mach-shmobile/hotplug.c
new file mode 100644
index 000000000000..238a0d97d2d5
--- /dev/null
+++ b/arch/arm/mach-shmobile/hotplug.c
@@ -0,0 +1,41 @@
1/*
2 * SMP support for R-Mobile / SH-Mobile
3 *
4 * Copyright (C) 2010 Magnus Damm
5 *
6 * Based on realview, Copyright (C) 2002 ARM Ltd, All Rights Reserved
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License version 2 as
10 * published by the Free Software Foundation.
11 */
12#include <linux/kernel.h>
13#include <linux/errno.h>
14#include <linux/smp.h>
15
16int platform_cpu_kill(unsigned int cpu)
17{
18 return 1;
19}
20
21void platform_cpu_die(unsigned int cpu)
22{
23 while (1) {
24 /*
25 * here's the WFI
26 */
27 asm(".word 0xe320f003\n"
28 :
29 :
30 : "memory", "cc");
31 }
32}
33
34int platform_cpu_disable(unsigned int cpu)
35{
36 /*
37 * we don't allow CPU 0 to be shutdown (it is still too special
38 * e.g. clock tick interrupts)
39 */
40 return cpu == 0 ? -EPERM : 0;
41}