Lines Matching +full:no +full:- +full:map
25 * no particular effort to keep them zero. It ensures that
160 void bitmap_set(unsigned long *map, long start, long nr) in bitmap_set() argument
162 unsigned long *p = map + BIT_WORD(start); in bitmap_set()
164 int bits_to_set = BITS_PER_LONG - (start % BITS_PER_LONG); in bitmap_set()
169 while (nr - bits_to_set >= 0) { in bitmap_set()
171 nr -= bits_to_set; in bitmap_set()
182 void bitmap_set_atomic(unsigned long *map, long start, long nr) in bitmap_set_atomic() argument
184 unsigned long *p = map + BIT_WORD(start); in bitmap_set_atomic()
186 int bits_to_set = BITS_PER_LONG - (start % BITS_PER_LONG); in bitmap_set_atomic()
192 if (nr - bits_to_set > 0) { in bitmap_set_atomic()
194 nr -= bits_to_set; in bitmap_set_atomic()
204 nr -= BITS_PER_LONG; in bitmap_set_atomic()
221 void bitmap_clear(unsigned long *map, long start, long nr) in bitmap_clear() argument
223 unsigned long *p = map + BIT_WORD(start); in bitmap_clear()
225 int bits_to_clear = BITS_PER_LONG - (start % BITS_PER_LONG); in bitmap_clear()
230 while (nr - bits_to_clear >= 0) { in bitmap_clear()
232 nr -= bits_to_clear; in bitmap_clear()
243 bool bitmap_test_and_clear(unsigned long *map, long start, long nr) in bitmap_test_and_clear() argument
245 unsigned long *p = map + BIT_WORD(start); in bitmap_test_and_clear()
247 int bits_to_clear = BITS_PER_LONG - (start % BITS_PER_LONG); in bitmap_test_and_clear()
254 if (nr - bits_to_clear > 0) { in bitmap_test_and_clear()
259 nr -= bits_to_clear; in bitmap_test_and_clear()
271 nr -= BITS_PER_LONG; in bitmap_test_and_clear()
288 bool bitmap_test_and_clear_atomic(unsigned long *map, long start, long nr) in bitmap_test_and_clear_atomic() argument
290 unsigned long *p = map + BIT_WORD(start); in bitmap_test_and_clear_atomic()
292 int bits_to_clear = BITS_PER_LONG - (start % BITS_PER_LONG); in bitmap_test_and_clear_atomic()
300 if (nr - bits_to_clear > 0) { in bitmap_test_and_clear_atomic()
303 nr -= bits_to_clear; in bitmap_test_and_clear_atomic()
316 nr -= BITS_PER_LONG; in bitmap_test_and_clear_atomic()
342 nr -= BITS_PER_LONG; in bitmap_copy_and_clear_atomic()
349 * bitmap_find_next_zero_area - find a contiguous aligned zero area
350 * @map: The address to base the search on
358 * power of 2. A @align_mask of 0 means no alignment is required.
360 unsigned long bitmap_find_next_zero_area(unsigned long *map, in bitmap_find_next_zero_area() argument
368 index = find_next_zero_bit(map, size, start); in bitmap_find_next_zero_area()
377 i = find_next_bit(map, end, index); in bitmap_find_next_zero_area()
471 right_mask = (1ul << shift) - 1; in bitmap_copy_with_src_offset()
476 *dst |= (src[1] & right_mask) << (BITS_PER_LONG - shift); in bitmap_copy_with_src_offset()
479 nbits -= BITS_PER_LONG; in bitmap_copy_with_src_offset()
482 if (nbits > BITS_PER_LONG - shift) { in bitmap_copy_with_src_offset()
484 nbits -= BITS_PER_LONG - shift; in bitmap_copy_with_src_offset()
485 last_mask = (1ul << nbits) - 1; in bitmap_copy_with_src_offset()
486 *dst |= (src[1] & last_mask) << (BITS_PER_LONG - shift); in bitmap_copy_with_src_offset()
488 last_mask = (1ul << nbits) - 1; in bitmap_copy_with_src_offset()
513 right_mask = (1ul << (BITS_PER_LONG - shift)) - 1; in bitmap_copy_with_dst_offset()
516 *dst &= (1ul << shift) - 1; in bitmap_copy_with_dst_offset()
519 dst[1] = (*src & left_mask) >> (BITS_PER_LONG - shift); in bitmap_copy_with_dst_offset()
522 nbits -= BITS_PER_LONG; in bitmap_copy_with_dst_offset()
525 if (nbits > BITS_PER_LONG - shift) { in bitmap_copy_with_dst_offset()
527 nbits -= BITS_PER_LONG - shift; in bitmap_copy_with_dst_offset()
528 last_mask = ((1ul << nbits) - 1) << (BITS_PER_LONG - shift); in bitmap_copy_with_dst_offset()
529 dst[1] = (*src & last_mask) >> (BITS_PER_LONG - shift); in bitmap_copy_with_dst_offset()
531 last_mask = (1ul << nbits) - 1; in bitmap_copy_with_dst_offset()