Lines Matching refs:cell
70 struct dm_bio_prison_cell *cell) in dm_bio_prison_free_cell() argument
72 mempool_free(cell, &prison->cell_pool); in dm_bio_prison_free_cell()
78 struct dm_bio_prison_cell *cell) in __setup_new_cell() argument
80 memcpy(&cell->key, key, sizeof(cell->key)); in __setup_new_cell()
81 cell->holder = holder; in __setup_new_cell()
82 bio_list_init(&cell->bios); in __setup_new_cell()
119 struct dm_bio_prison_cell *cell = in __bio_detain() local
122 r = cmp_keys(key, &cell->key); in __bio_detain()
131 bio_list_add(&cell->bios, inmate); in __bio_detain()
132 *cell_result = cell; in __bio_detain()
184 struct dm_bio_prison_cell *cell, in __cell_release() argument
187 rb_erase(&cell->node, &prison->cells); in __cell_release()
190 if (cell->holder) in __cell_release()
191 bio_list_add(inmates, cell->holder); in __cell_release()
192 bio_list_merge(inmates, &cell->bios); in __cell_release()
197 struct dm_bio_prison_cell *cell, in dm_cell_release() argument
201 __cell_release(prison, cell, bios); in dm_cell_release()
210 struct dm_bio_prison_cell *cell, in __cell_release_no_holder() argument
213 rb_erase(&cell->node, &prison->cells); in __cell_release_no_holder()
214 bio_list_merge(inmates, &cell->bios); in __cell_release_no_holder()
218 struct dm_bio_prison_cell *cell, in dm_cell_release_no_holder() argument
224 __cell_release_no_holder(prison, cell, inmates); in dm_cell_release_no_holder()
230 struct dm_bio_prison_cell *cell, blk_status_t error) in dm_cell_error() argument
236 dm_cell_release(prison, cell, &bios); in dm_cell_error()
248 struct dm_bio_prison_cell *cell) in dm_cell_visit_release() argument
251 visit_fn(context, cell); in dm_cell_visit_release()
252 rb_erase(&cell->node, &prison->cells); in dm_cell_visit_release()
258 struct dm_bio_prison_cell *cell) in __promote_or_release() argument
260 if (bio_list_empty(&cell->bios)) { in __promote_or_release()
261 rb_erase(&cell->node, &prison->cells); in __promote_or_release()
265 cell->holder = bio_list_pop(&cell->bios); in __promote_or_release()
270 struct dm_bio_prison_cell *cell) in dm_cell_promote_or_release() argument
275 r = __promote_or_release(prison, cell); in dm_cell_promote_or_release()