]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
sched, sparc64: Turn cpu_coregroup_mask() into a real function
authorStephen Rothwell <sfr@canb.auug.org.au>
Tue, 12 Apr 2011 04:00:40 +0000 (14:00 +1000)
committerIngo Molnar <mingo@elte.hu>
Tue, 12 Apr 2011 06:46:41 +0000 (08:46 +0200)
This compile error triggers on Sparc64:

   kernel/sched.c:7140: error: 'cpu_coregroup_mask' undeclared here (not in a function)

Because after the recent scheduler domain cleanups the scheduler
uses this arch method as a function pointer in a scheduler
topology data structure - which is not possible with a macro.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Acked-by: David S. Miller <davem@davemloft.net>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20110412140040.3020ef55.sfr@canb.auug.org.au
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/sparc/include/asm/topology_64.h

index 1c79f32734a05694a5297c7034ff0e6b93fe83f6..8b9c556d630b8731c76b16d1708d090dbd6d4cfc 100644 (file)
@@ -65,6 +65,10 @@ static inline int pcibus_to_node(struct pci_bus *pbus)
 #define smt_capable()                          (sparc64_multi_core)
 #endif /* CONFIG_SMP */
 
-#define cpu_coregroup_mask(cpu)                        (&cpu_core_map[cpu])
+extern cpumask_t cpu_core_map[NR_CPUS];
+static inline const struct cpumask *cpu_coregroup_mask(int cpu)
+{
+        return &cpu_core_map[cpu];
+}
 
 #endif /* _ASM_SPARC64_TOPOLOGY_H */