Lines Matching refs:id

16 int item_idr_free(int id, void *p, void *data)  in item_idr_free()  argument
19 assert(item->index == id); in item_idr_free()
25 void item_idr_remove(struct idr *idr, int id) in item_idr_remove() argument
27 struct item *item = idr_find(idr, id); in item_idr_remove()
28 assert(item->index == id); in item_idr_remove()
29 idr_remove(idr, id); in item_idr_remove()
44 int id; in idr_alloc_test() local
52 id = idr_alloc_cyclic(&idr, item, 1, 0x4000, GFP_KERNEL); in idr_alloc_test()
53 assert(id == item->index); in idr_alloc_test()
173 int idr_u32_cb(int id, void *ptr, void *data) in idr_u32_cb() argument
175 BUG_ON(id < 0); in idr_u32_cb()
183 u32 id = handle; in idr_u32_test1() local
187 BUG_ON(idr_alloc_u32(idr, DUMMY_PTR, &id, id, GFP_KERNEL)); in idr_u32_test1()
188 BUG_ON(id != handle); in idr_u32_test1()
189 BUG_ON(idr_alloc_u32(idr, DUMMY_PTR, &id, id, GFP_KERNEL) != -ENOSPC); in idr_u32_test1()
190 BUG_ON(id != handle); in idr_u32_test1()
191 if (!warned && id > INT_MAX) in idr_u32_test1()
194 if (id > INT_MAX) { in idr_u32_test1()
199 BUG_ON(sid != id); in idr_u32_test1()
202 if (!warned && id > INT_MAX) { in idr_u32_test1()
206 BUG_ON(idr_remove(idr, id) != DUMMY_PTR); in idr_u32_test1()
225 int i, id; in idr_align_test() local
230 idr_for_each_entry(idr, entry, id); in idr_align_test()
236 idr_for_each_entry(idr, entry, id); in idr_align_test()
242 idr_for_each_entry(idr, entry, id); in idr_align_test()
248 idr_for_each_entry(idr, entry, id); in idr_align_test()
255 idr_for_each_entry(idr, entry, id); in idr_align_test()
257 idr_for_each_entry(idr, entry, id); in idr_align_test()
264 idr_for_each_entry(idr, entry, id); in idr_align_test()
266 idr_for_each_entry(idr, entry, id); in idr_align_test()
275 idr_for_each_entry(idr, entry, id); in idr_align_test()
277 idr_for_each_entry(idr, entry, id); in idr_align_test()
287 int id = *(int *)arg; in idr_throbber() local
291 idr_alloc(&find_idr, xa_mk_value(id), id, id + 1, GFP_KERNEL); in idr_throbber()
292 idr_remove(&find_idr, id); in idr_throbber()
315 int id = 0; in idr_find_test_1() local
316 void *entry = idr_get_next(&find_idr, &id); in idr_find_test_1()
318 if ((id != anchor_id && id != throbber_id) || in idr_find_test_1()
319 entry != xa_mk_value(id)) { in idr_find_test_1()
321 throbber_id, entry, id); in idr_find_test_1()
388 unsigned int id; in idr_checks() local
394 id = idr_alloc_cyclic(&idr, item, 0, 0, GFP_KERNEL); in idr_checks()
395 assert(id == item->index); in idr_checks()
442 int id; in ida_check_nomem() local
444 id = ida_alloc_min(&ida, 256, GFP_NOWAIT); in ida_check_nomem()
445 IDA_BUG_ON(&ida, id != -ENOMEM); in ida_check_nomem()
446 id = ida_alloc_min(&ida, 1UL << 30, GFP_NOWAIT); in ida_check_nomem()
447 IDA_BUG_ON(&ida, id != -ENOMEM); in ida_check_nomem()
460 int id = ida_alloc(&ida, GFP_NOWAIT); in ida_check_conv_user() local
461 if (id == -ENOMEM) { in ida_check_conv_user()
465 id = ida_alloc(&ida, GFP_KERNEL); in ida_check_conv_user()
470 IDA_BUG_ON(&ida, id != i); in ida_check_conv_user()