diff options
Diffstat (limited to 'tools/lib/bitmap.c')
-rw-r--r-- | tools/lib/bitmap.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/lib/bitmap.c b/tools/lib/bitmap.c index e1fafc131a49..c3e4871967bc 100644 --- a/tools/lib/bitmap.c +++ b/tools/lib/bitmap.c @@ -5,9 +5,9 @@ */ #include <linux/bitmap.h> -unsigned long __bitmap_weight(const unsigned long *bitmap, unsigned int bits) +unsigned int __bitmap_weight(const unsigned long *bitmap, int bits) { - unsigned long k, w = 0, lim = bits/BITS_PER_LONG; + unsigned int k, w = 0, lim = bits/BITS_PER_LONG; for (k = 0; k < lim; k++) w += hweight_long(bitmap[k]); |