[PATCH] cpumask: export cpu_online_map and cpu_possible_map consistently
authorGreg Banks <gnb@melbourne.sgi.com>
Mon, 2 Oct 2006 09:17:40 +0000 (02:17 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 2 Oct 2006 14:57:17 +0000 (07:57 -0700)
cpumask: ensure that the cpu_online_map and cpu_possible_map bitmasks, and
hence all the macros in <linux/cpumask.h> that require them, are available to
modules for all supported combinations of architecture and CONFIG_SMP.

Signed-off-by: Greg Banks <gnb@melbourne.sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/arm/kernel/smp.c
arch/cris/arch-v32/kernel/smp.c
arch/sh/kernel/smp.c
kernel/sched.c

index 68e9634d260a74c8a1d21d93db7a2421fa376859..421329f5e18e6ea0a8e336b4a32543622f1c0895 100644 (file)
@@ -36,7 +36,9 @@
  * The online bitmask indicates that the CPU is up and running.
  */
 cpumask_t cpu_possible_map;
+EXPORT_SYMBOL(cpu_possible_map);
 cpumask_t cpu_online_map;
+EXPORT_SYMBOL(cpu_online_map);
 
 /*
  * as from 2.5, kernels no longer have an init_tasks structure
index 464ecaec3bc08d8ef21878fac55bbbdf05cc6d74..2d0023f2d49bc01ade50767f8b2f9d9584034691 100644 (file)
@@ -28,6 +28,7 @@ spinlock_t cris_atomic_locks[] = { [0 ... LOCK_COUNT - 1] = SPIN_LOCK_UNLOCKED};
 
 /* CPU masks */
 cpumask_t cpu_online_map = CPU_MASK_NONE;
+EXPORT_SYMBOL(cpu_online_map);
 cpumask_t phys_cpu_present_map = CPU_MASK_NONE;
 EXPORT_SYMBOL(phys_cpu_present_map);
 
index 6c0fb7c4af1190f40f1fcca3f93b2e15a82fedc9..dbebaddcfe394974686c833a39f837d562720fa5 100644 (file)
@@ -42,6 +42,7 @@ cpumask_t cpu_possible_map;
 EXPORT_SYMBOL(cpu_possible_map);
 
 cpumask_t cpu_online_map;
+EXPORT_SYMBOL(cpu_online_map);
 static atomic_t cpus_booted = ATOMIC_INIT(0);
 
 /* These are defined by the board-specific code. */
index 2bbd948f0169dc3361d8b8924b0dce59eda1a825..e4e54e86f4a2215b3de2c6da593cd3974ddfa3d0 100644 (file)
@@ -4384,7 +4384,10 @@ EXPORT_SYMBOL(cpu_present_map);
 
 #ifndef CONFIG_SMP
 cpumask_t cpu_online_map __read_mostly = CPU_MASK_ALL;
+EXPORT_SYMBOL(cpu_online_map);
+
 cpumask_t cpu_possible_map __read_mostly = CPU_MASK_ALL;
+EXPORT_SYMBOL(cpu_possible_map);
 #endif
 
 long sched_getaffinity(pid_t pid, cpumask_t *mask)