diff options
author | Olof Johansson <olof@lixom.net> | 2012-09-22 03:06:21 -0400 |
---|---|---|
committer | Olof Johansson <olof@lixom.net> | 2012-09-22 03:16:04 -0400 |
commit | 25468fe89f88c4ceeef94526e94ae0db176f6999 (patch) | |
tree | d70a713525281276b5063c814413bb3141e6056c /arch/arm/mach-realview | |
parent | a283580c52d3aa24305985e945dfccfbcfc6f4f9 (diff) | |
parent | 28e8e29c616f947348cc66bea684d0035c76021a (diff) |
Merge branch 'multiplatform/smp_ops' into next/multiplatform
* multiplatform/smp_ops:
ARM: consolidate pen_release instead of having per platform definitions
ARM: smp: Make SMP operations mandatory
ARM: SoC: convert spear13xx to SMP operations
ARM: SoC: convert imx6q to SMP operations
ARM: SoC: convert highbank to SMP operations
ARM: SoC: convert shmobile SMP to SMP operations
ARM: SoC: convert ux500 to SMP operations
ARM: SoC: convert MSM to SMP operations
ARM: SoC: convert Exynos4 to SMP operations
ARM: SoC: convert Tegra to SMP operations
ARM: SoC: convert OMAP4 to SMP operations
ARM: SoC: convert VExpress/RealView to SMP operations
ARM: SoC: add per-platform SMP operations
Conflicts due to file moves or removals in:
arch/arm/mach-msm/board-msm8960.c
arch/arm/mach-msm/board-msm8x60.c
arch/arm/mach-tegra/board-harmony.c
arch/arm/mach-tegra/board-trimslice.c
Conflicts due to board file cleanup:
arch/arm/mach-tegra/board-paz00.c
Conflicts due to cpu hotplug addition:
arch/arm/mach-tegra/hotplug.c
Signed-off-by: Olof Johansson <olof@lixom.net>
Diffstat (limited to 'arch/arm/mach-realview')
-rw-r--r-- | arch/arm/mach-realview/core.h | 3 | ||||
-rw-r--r-- | arch/arm/mach-realview/hotplug.c | 18 | ||||
-rw-r--r-- | arch/arm/mach-realview/platsmp.c | 18 | ||||
-rw-r--r-- | arch/arm/mach-realview/realview_pb11mp.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-realview/realview_pbx.c | 1 |
5 files changed, 20 insertions, 21 deletions
diff --git a/arch/arm/mach-realview/core.h b/arch/arm/mach-realview/core.h index f8f2c0ac4c01..78cd970c80f2 100644 --- a/arch/arm/mach-realview/core.h +++ b/arch/arm/mach-realview/core.h | |||
@@ -56,4 +56,7 @@ extern void realview_init_early(void); | |||
56 | extern void realview_fixup(struct tag *tags, char **from, | 56 | extern void realview_fixup(struct tag *tags, char **from, |
57 | struct meminfo *meminfo); | 57 | struct meminfo *meminfo); |
58 | 58 | ||
59 | extern struct smp_operations realview_smp_ops; | ||
60 | extern void realview_cpu_die(unsigned int cpu); | ||
61 | |||
59 | #endif | 62 | #endif |
diff --git a/arch/arm/mach-realview/hotplug.c b/arch/arm/mach-realview/hotplug.c index 57d9efba2956..53818e5cd3ad 100644 --- a/arch/arm/mach-realview/hotplug.c +++ b/arch/arm/mach-realview/hotplug.c | |||
@@ -16,8 +16,6 @@ | |||
16 | #include <asm/cp15.h> | 16 | #include <asm/cp15.h> |
17 | #include <asm/smp_plat.h> | 17 | #include <asm/smp_plat.h> |
18 | 18 | ||
19 | extern volatile int pen_release; | ||
20 | |||
21 | static inline void cpu_enter_lowpower(void) | 19 | static inline void cpu_enter_lowpower(void) |
22 | { | 20 | { |
23 | unsigned int v; | 21 | unsigned int v; |
@@ -89,17 +87,12 @@ static inline void platform_do_lowpower(unsigned int cpu, int *spurious) | |||
89 | } | 87 | } |
90 | } | 88 | } |
91 | 89 | ||
92 | int platform_cpu_kill(unsigned int cpu) | ||
93 | { | ||
94 | return 1; | ||
95 | } | ||
96 | |||
97 | /* | 90 | /* |
98 | * platform-specific code to shutdown a CPU | 91 | * platform-specific code to shutdown a CPU |
99 | * | 92 | * |
100 | * Called with IRQs disabled | 93 | * Called with IRQs disabled |
101 | */ | 94 | */ |
102 | void platform_cpu_die(unsigned int cpu) | 95 | void __ref realview_cpu_die(unsigned int cpu) |
103 | { | 96 | { |
104 | int spurious = 0; | 97 | int spurious = 0; |
105 | 98 | ||
@@ -118,12 +111,3 @@ void platform_cpu_die(unsigned int cpu) | |||
118 | if (spurious) | 111 | if (spurious) |
119 | pr_warn("CPU%u: %u spurious wakeup calls\n", cpu, spurious); | 112 | pr_warn("CPU%u: %u spurious wakeup calls\n", cpu, spurious); |
120 | } | 113 | } |
121 | |||
122 | int platform_cpu_disable(unsigned int cpu) | ||
123 | { | ||
124 | /* | ||
125 | * we don't allow CPU 0 to be shutdown (it is still too special | ||
126 | * e.g. clock tick interrupts) | ||
127 | */ | ||
128 | return cpu == 0 ? -EPERM : 0; | ||
129 | } | ||
diff --git a/arch/arm/mach-realview/platsmp.c b/arch/arm/mach-realview/platsmp.c index 17c878ddbc70..300f7064465d 100644 --- a/arch/arm/mach-realview/platsmp.c +++ b/arch/arm/mach-realview/platsmp.c | |||
@@ -22,9 +22,9 @@ | |||
22 | #include <mach/board-pb11mp.h> | 22 | #include <mach/board-pb11mp.h> |
23 | #include <mach/board-pbx.h> | 23 | #include <mach/board-pbx.h> |
24 | 24 | ||
25 | #include "core.h" | 25 | #include <plat/platsmp.h> |
26 | 26 | ||
27 | extern void versatile_secondary_startup(void); | 27 | #include "core.h" |
28 | 28 | ||
29 | static void __iomem *scu_base_addr(void) | 29 | static void __iomem *scu_base_addr(void) |
30 | { | 30 | { |
@@ -43,7 +43,7 @@ static void __iomem *scu_base_addr(void) | |||
43 | * Initialise the CPU possible map early - this describes the CPUs | 43 | * Initialise the CPU possible map early - this describes the CPUs |
44 | * which may be present or become present in the system. | 44 | * which may be present or become present in the system. |
45 | */ | 45 | */ |
46 | void __init smp_init_cpus(void) | 46 | static void __init realview_smp_init_cpus(void) |
47 | { | 47 | { |
48 | void __iomem *scu_base = scu_base_addr(); | 48 | void __iomem *scu_base = scu_base_addr(); |
49 | unsigned int i, ncores; | 49 | unsigned int i, ncores; |
@@ -63,7 +63,7 @@ void __init smp_init_cpus(void) | |||
63 | set_smp_cross_call(gic_raise_softirq); | 63 | set_smp_cross_call(gic_raise_softirq); |
64 | } | 64 | } |
65 | 65 | ||
66 | void __init platform_smp_prepare_cpus(unsigned int max_cpus) | 66 | static void __init realview_smp_prepare_cpus(unsigned int max_cpus) |
67 | { | 67 | { |
68 | 68 | ||
69 | scu_enable(scu_base_addr()); | 69 | scu_enable(scu_base_addr()); |
@@ -77,3 +77,13 @@ void __init platform_smp_prepare_cpus(unsigned int max_cpus) | |||
77 | __raw_writel(virt_to_phys(versatile_secondary_startup), | 77 | __raw_writel(virt_to_phys(versatile_secondary_startup), |
78 | __io_address(REALVIEW_SYS_FLAGSSET)); | 78 | __io_address(REALVIEW_SYS_FLAGSSET)); |
79 | } | 79 | } |
80 | |||
81 | struct smp_operations realview_smp_ops __initdata = { | ||
82 | .smp_init_cpus = realview_smp_init_cpus, | ||
83 | .smp_prepare_cpus = realview_smp_prepare_cpus, | ||
84 | .smp_secondary_init = versatile_secondary_init, | ||
85 | .smp_boot_secondary = versatile_boot_secondary, | ||
86 | #ifdef CONFIG_HOTPLUG_CPU | ||
87 | .cpu_die = realview_cpu_die, | ||
88 | #endif | ||
89 | }; | ||
diff --git a/arch/arm/mach-realview/realview_pb11mp.c b/arch/arm/mach-realview/realview_pb11mp.c index b442fb276d57..a80269981dd4 100644 --- a/arch/arm/mach-realview/realview_pb11mp.c +++ b/arch/arm/mach-realview/realview_pb11mp.c | |||
@@ -367,6 +367,7 @@ static void __init realview_pb11mp_init(void) | |||
367 | MACHINE_START(REALVIEW_PB11MP, "ARM-RealView PB11MPCore") | 367 | MACHINE_START(REALVIEW_PB11MP, "ARM-RealView PB11MPCore") |
368 | /* Maintainer: ARM Ltd/Deep Blue Solutions Ltd */ | 368 | /* Maintainer: ARM Ltd/Deep Blue Solutions Ltd */ |
369 | .atag_offset = 0x100, | 369 | .atag_offset = 0x100, |
370 | .smp = smp_ops(realview_smp_ops), | ||
370 | .fixup = realview_fixup, | 371 | .fixup = realview_fixup, |
371 | .map_io = realview_pb11mp_map_io, | 372 | .map_io = realview_pb11mp_map_io, |
372 | .init_early = realview_init_early, | 373 | .init_early = realview_init_early, |
diff --git a/arch/arm/mach-realview/realview_pbx.c b/arch/arm/mach-realview/realview_pbx.c index 5d2c8bebb069..a4b1aa93bb5a 100644 --- a/arch/arm/mach-realview/realview_pbx.c +++ b/arch/arm/mach-realview/realview_pbx.c | |||
@@ -404,6 +404,7 @@ static void __init realview_pbx_init(void) | |||
404 | MACHINE_START(REALVIEW_PBX, "ARM-RealView PBX") | 404 | MACHINE_START(REALVIEW_PBX, "ARM-RealView PBX") |
405 | /* Maintainer: ARM Ltd/Deep Blue Solutions Ltd */ | 405 | /* Maintainer: ARM Ltd/Deep Blue Solutions Ltd */ |
406 | .atag_offset = 0x100, | 406 | .atag_offset = 0x100, |
407 | .smp = smp_ops(realview_smp_ops), | ||
407 | .fixup = realview_pbx_fixup, | 408 | .fixup = realview_pbx_fixup, |
408 | .map_io = realview_pbx_map_io, | 409 | .map_io = realview_pbx_map_io, |
409 | .init_early = realview_init_early, | 410 | .init_early = realview_init_early, |