Lines Matching refs:bio
17 void bch_bbio_free(struct bio *bio, struct cache_set *c)
19 struct bbio *b = container_of(bio, struct bbio, bio);
24 struct bio *bch_bbio_alloc(struct cache_set *c)
27 struct bio *bio = &b->bio;
29 bio_init(bio, NULL, bio->bi_inline_vecs,
32 return bio;
35 void __bch_submit_bbio(struct bio *bio, struct cache_set *c)
37 struct bbio *b = container_of(bio, struct bbio, bio);
39 bio->bi_iter.bi_sector = PTR_OFFSET(&b->key, 0);
40 bio_set_dev(bio, c->cache->bdev);
43 closure_bio_submit(c, bio, bio->bi_private);
46 void bch_submit_bbio(struct bio *bio, struct cache_set *c,
49 struct bbio *b = container_of(bio, struct bbio, bio);
52 __bch_submit_bbio(bio, c);
56 void bch_count_backing_io_errors(struct cached_dev *dc, struct bio *bio)
66 * we shouldn't count failed REQ_RAHEAD bio to dc->io_errors.
68 if (bio->bi_opf & REQ_RAHEAD) {
137 void bch_bbio_count_io_errors(struct cache_set *c, struct bio *bio,
140 struct bbio *b = container_of(bio, struct bbio, bio);
142 int is_read = (bio_data_dir(bio) == READ ? 1 : 0);
144 unsigned int threshold = op_is_write(bio_op(bio))
167 void bch_bbio_endio(struct cache_set *c, struct bio *bio,
170 struct closure *cl = bio->bi_private;
172 bch_bbio_count_io_errors(c, bio, error, m);
173 bio_put(bio);