summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2008-06-20 10:05:19 +1000
committerStephen Rothwell <sfr@canb.auug.org.au>2008-06-20 10:05:19 +1000
commite00add8be99e85f1849cd340dde95ddc5b38ecbd (patch)
treeabdbb95344e6db1031a1af254c3f5c8c61ca92df /lib
parent6fcb9a97c4137df1587ade5896e8bd1b2a53115c (diff)
parent5b8201ce87f87af3bebc8072b03d3989f92e144a (diff)
Merge commit 'cpus4096/auto-cpus4096-next'
Diffstat (limited to 'lib')
-rw-r--r--lib/cpumask.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/cpumask.c b/lib/cpumask.c
index bb4f76d3c3e7..5f97dc25ef9c 100644
--- a/lib/cpumask.c
+++ b/lib/cpumask.c
@@ -15,6 +15,15 @@ int __next_cpu(int n, const cpumask_t *srcp)
}
EXPORT_SYMBOL(__next_cpu);
+#if NR_CPUS > 64
+int __next_cpu_nr(int n, const cpumask_t *srcp)
+{
+ return min_t(int, nr_cpu_ids,
+ find_next_bit(srcp->bits, nr_cpu_ids, n+1));
+}
+EXPORT_SYMBOL(__next_cpu_nr);
+#endif
+
int __any_online_cpu(const cpumask_t *mask)
{
int cpu;