Lines Matching defs:ref
88 reference_t *ref;
91 while (ref = list_head(&rc->rc_list)) {
92 list_remove(&rc->rc_list, ref);
93 kmem_cache_free(reference_cache, ref);
97 while (ref = list_head(&rc->rc_removed)) {
98 list_remove(&rc->rc_removed, ref);
99 kmem_cache_free(reference_history_cache, ref->ref_removed);
100 kmem_cache_free(reference_cache, ref);
127 reference_t *ref = NULL;
131 ref = kmem_cache_alloc(reference_cache, KM_SLEEP);
132 ref->ref_holder = holder;
133 ref->ref_number = number;
138 list_insert_head(&rc->rc_list, ref);
155 reference_t *ref;
168 for (ref = list_head(&rc->rc_list); ref;
169 ref = list_next(&rc->rc_list, ref)) {
170 if (ref->ref_holder == holder && ref->ref_number == number) {
171 list_remove(&rc->rc_list, ref);
173 ref->ref_removed =
176 list_insert_head(&rc->rc_removed, ref);
179 ref = list_tail(&rc->rc_removed);
180 list_remove(&rc->rc_removed, ref);
182 ref->ref_removed);
183 kmem_cache_free(reference_cache, ref);
187 kmem_cache_free(reference_cache, ref);
241 reference_t *ref;
250 for (ref = list_head(&rc->rc_list); ref;
251 ref = list_next(&rc->rc_list, ref)) {
252 if (ref->ref_holder == current_holder) {
253 ref->ref_holder = new_holder;
270 reference_t *ref;
279 for (ref = list_head(&rc->rc_list); ref;
280 ref = list_next(&rc->rc_list, ref)) {
281 if (ref->ref_holder == holder) {
298 reference_t *ref;
307 for (ref = list_head(&rc->rc_list); ref;
308 ref = list_next(&rc->rc_list, ref)) {
309 if (ref->ref_holder == holder) {