Lines Matching defs:range
34 fr_isfull(struct idr_free_id_range *range)
36 return range->min_unused_id >= range->end;
53 fr_destroy(struct idr_free_id_range *range)
58 while (range->free_ids) {
59 id = range->free_ids;
60 range->free_ids = range->free_ids->next;
64 ret = range->next;
65 kmem_free(range, sizeof(struct idr_free_id_range));
92 /* link the new range */
106 /* link free id to the new range */
115 /* remove from the prev range */
118 /* link to the new range */
142 idr_get_free_id_in_range(struct idr_free_id_range* range)
147 if (range->free_ids) {
148 idp = range->free_ids;
149 range->free_ids = idp->next;
155 if (!fr_isfull(range)) {
156 id = range->min_unused_id;
157 range->min_unused_id++;
178 struct idr_free_id_range *range;
184 range = fr_get(idrp->free_id_ranges, start);
185 if (!range)
186 range = fr_insert(idrp->free_id_ranges, start);
188 while (range) {
189 id = idr_get_free_id_in_range(range);
192 range = range->next;
248 struct idr_free_id_range *range;
267 range = idrp->free_id_ranges;
268 while (range->end <= id)
269 range = range->next;
270 fid->next = range->free_ids;
271 range->free_ids = fid;
332 struct idr_free_id_range *range;
340 range = idrp->free_id_ranges;
341 while (range)
342 range = fr_destroy(range);