projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge tag 'dm-4.2-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/device...
[firefly-linux-kernel-4.4.55.git]
/
lib
/
cpumask.c
diff --git
a/lib/cpumask.c
b/lib/cpumask.c
index 5f627084f2e998b2605016c311411d91f7016918..5a70f6196f577a071ae0a31e9da7fa0e1dd1bc68 100644
(file)
--- a/
lib/cpumask.c
+++ b/
lib/cpumask.c
@@
-16,11
+16,10
@@
int cpumask_next_and(int n, const struct cpumask *src1p,
const struct cpumask *src2p)
{
int cpumask_next_and(int n, const struct cpumask *src1p,
const struct cpumask *src2p)
{
- struct cpumask tmp;
-
- if (cpumask_and(&tmp, src1p, src2p))
- return cpumask_next(n, &tmp);
- return nr_cpu_ids;
+ while ((n = cpumask_next(n, src1p)) < nr_cpu_ids)
+ if (cpumask_test_cpu(n, src2p))
+ break;
+ return n;
}
EXPORT_SYMBOL(cpumask_next_and);
}
EXPORT_SYMBOL(cpumask_next_and);