Lines Matching refs:bit_pos
156 u64 bit_pos = -1; in find_free_range() local
163 bit_pos = find_first_bit(lam, num_bits); in find_free_range()
167 __func__, bit_pos, bali->lun_alloc_map[i], i); in find_free_range()
171 clear_bit(bit_pos, lam); in find_free_range()
175 return bit_pos; in find_free_range()
186 u64 bit_pos = -1; in ba_alloc() local
203 bit_pos = find_free_range(bali->free_curr_idx, in ba_alloc()
205 if (bit_pos == -1) { in ba_alloc()
206 bit_pos = find_free_range(bali->free_low_idx, in ba_alloc()
209 if (bit_pos == -1) { in ba_alloc()
217 if (bit_pos == HIBIT) in ba_alloc()
224 ((bit_word * BITS_PER_LONG) + bit_pos), ba_lun->lun_id, in ba_alloc()
227 return (u64) ((bit_word * BITS_PER_LONG) + bit_pos); in ba_alloc()
239 int idx = 0, bit_pos = 0; in validate_alloc() local
242 bit_pos = aun % BITS_PER_LONG; in validate_alloc()
244 if (test_bit(bit_pos, (ulong *)&bali->lun_alloc_map[idx])) in validate_alloc()
259 int idx = 0, bit_pos = 0; in ba_free() local
283 bit_pos = to_free % BITS_PER_LONG; in ba_free()
285 set_bit(bit_pos, (ulong *)&bali->lun_alloc_map[idx]); in ba_free()
294 "lun_id=%016llx free_aun_cnt=%llx\n", __func__, bit_pos, idx, in ba_free()