aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/include
diff options
context:
space:
mode:
authorJesse Larrew <jlarrew@linux.vnet.ibm.com>2010-12-17 17:07:47 -0500
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2011-01-11 00:06:16 -0500
commit39bf990ead35c7263652ca5dd8262b2b2cd147ac (patch)
tree2aac1543090234a97d4b67f1871bbfcd857359e2 /arch/powerpc/include
parenteed0ba0b4ab2d1668588219a8efa81bf8636a12d (diff)
powerpc/pseries: Fix VPHN build errors on non-SMP systems
The header asm/hvcall.h was previously included indirectly via smp.h. On non-SMP systems, however, these declarations are excluded and the build breaks. This is easily fixed by including asm/hvcall.h directly. The VPHN feature is only meaningful on NUMA systems that implement the SPLPAR option, so exclude the VPHN code on systems without SPLPAR enabled. Also, expose unmap_cpu_from_node() on systems with SPLPAR enabled, even if CONFIG_HOTPLUG_CPU is disabled. Lastly, map_cpu_to_node() is now needed by VPHN to manipulate the node masks after boot time, so remove the __cpuinit annotation to fix a section mismatch. Signed-off-by: Jesse Larrew <jlarrew@linux.vnet.ibm.com>
Diffstat (limited to 'arch/powerpc/include')
-rw-r--r--arch/powerpc/include/asm/topology.h20
1 files changed, 11 insertions, 9 deletions
diff --git a/arch/powerpc/include/asm/topology.h b/arch/powerpc/include/asm/topology.h
index aed188bd70db..fbfcfd04d25a 100644
--- a/arch/powerpc/include/asm/topology.h
+++ b/arch/powerpc/include/asm/topology.h
@@ -93,9 +93,20 @@ extern void __init dump_numa_cpu_topology(void);
93extern int sysfs_add_device_to_node(struct sys_device *dev, int nid); 93extern int sysfs_add_device_to_node(struct sys_device *dev, int nid);
94extern void sysfs_remove_device_from_node(struct sys_device *dev, int nid); 94extern void sysfs_remove_device_from_node(struct sys_device *dev, int nid);
95 95
96#ifdef CONFIG_PPC_SPLPAR
96extern int start_topology_update(void); 97extern int start_topology_update(void);
97extern int stop_topology_update(void); 98extern int stop_topology_update(void);
98#else 99#else
100static inline int start_topology_update(void)
101{
102 return 0;
103}
104static inline int stop_topology_update(void)
105{
106 return 0;
107}
108#endif /* CONFIG_PPC_SPLPAR */
109#else
99 110
100static inline void dump_numa_cpu_topology(void) {} 111static inline void dump_numa_cpu_topology(void) {}
101 112
@@ -108,15 +119,6 @@ static inline void sysfs_remove_device_from_node(struct sys_device *dev,
108 int nid) 119 int nid)
109{ 120{
110} 121}
111
112static inline int start_topology_update(void)
113{
114 return 0;
115}
116static inline int stop_topology_update(void)
117{
118 return 0;
119}
120#endif /* CONFIG_NUMA */ 122#endif /* CONFIG_NUMA */
121 123
122#include <asm-generic/topology.h> 124#include <asm-generic/topology.h>