Home
last modified time | relevance | path

Searched refs:bio (Results 1 – 25 of 59) sorted by relevance

123

/fs/ext4/
Dreadpage.c64 struct bio *bio; member
70 static void __read_end_io(struct bio *bio) in __read_end_io() argument
76 bio_for_each_segment_all(bv, bio, iter_all) { in __read_end_io()
80 if (bio->bi_status || PageError(page)) { in __read_end_io()
89 if (bio->bi_private) in __read_end_io()
90 mempool_free(bio->bi_private, bio_post_read_ctx_pool); in __read_end_io()
91 bio_put(bio); in __read_end_io()
101 fscrypt_decrypt_bio(ctx->bio); in decrypt_work()
111 fsverity_verify_bio(ctx->bio); in verity_work()
141 __read_end_io(ctx->bio); in bio_post_read_processing()
[all …]
Dpage-io.c62 static void ext4_finish_bio(struct bio *bio) in ext4_finish_bio() argument
67 bio_for_each_segment_all(bvec, bio, iter_all) { in ext4_finish_bio()
84 if (bio->bi_status) { in ext4_finish_bio()
103 if (bio->bi_status) in ext4_finish_bio()
117 struct bio *bio, *next_bio; in ext4_release_io_end() local
123 for (bio = io_end->bio; bio; bio = next_bio) { in ext4_release_io_end()
124 next_bio = bio->bi_private; in ext4_release_io_end()
125 ext4_finish_bio(bio); in ext4_release_io_end()
126 bio_put(bio); in ext4_release_io_end()
289 static void ext4_end_bio(struct bio *bio) in ext4_end_bio() argument
[all …]
/fs/
Dmpage.c55 static void mpage_end_io(struct bio *bio) in mpage_end_io() argument
61 (bio_data_dir(bio) == READ)) { in mpage_end_io()
62 struct page *first_page = bio->bi_io_vec[0].bv_page; in mpage_end_io()
67 bio->bi_iter.bi_size); in mpage_end_io()
70 bio_for_each_segment_all(bv, bio, iter_all) { in mpage_end_io()
72 page_endio(page, bio_op(bio), in mpage_end_io()
73 blk_status_to_errno(bio->bi_status)); in mpage_end_io()
76 bio_put(bio); in mpage_end_io()
79 static struct bio *mpage_bio_submit(int op, int op_flags, struct bio *bio) in mpage_bio_submit() argument
82 struct page *first_page = bio->bi_io_vec[0].bv_page; in mpage_bio_submit()
[all …]
Ddirect-io.c70 struct bio *bio; /* bio under assembly */ member
137 struct bio *bio_list; /* singly linked via bi_private */
345 static blk_status_t dio_bio_complete(struct dio *dio, struct bio *bio);
350 static void dio_bio_end_aio(struct bio *bio) in dio_bio_end_aio() argument
352 struct dio *dio = bio->bi_private; in dio_bio_end_aio()
358 dio_bio_complete(dio, bio); in dio_bio_end_aio()
396 static void dio_bio_end_io(struct bio *bio) in dio_bio_end_io() argument
398 struct dio *dio = bio->bi_private; in dio_bio_end_io()
402 bio->bi_private = dio->bio_list; in dio_bio_end_io()
403 dio->bio_list = bio; in dio_bio_end_io()
[all …]
Dblock_dev.c193 static void blkdev_bio_end_io_simple(struct bio *bio) in blkdev_bio_end_io_simple() argument
195 struct task_struct *waiter = bio->bi_private; in blkdev_bio_end_io_simple()
197 WRITE_ONCE(bio->bi_private, NULL); in blkdev_bio_end_io_simple()
210 struct bio bio; in __blkdev_direct_IO_simple() local
227 bio_init(&bio, vecs, nr_pages); in __blkdev_direct_IO_simple()
228 bio_set_dev(&bio, bdev); in __blkdev_direct_IO_simple()
229 bio.bi_iter.bi_sector = pos >> 9; in __blkdev_direct_IO_simple()
230 bio.bi_write_hint = iocb->ki_hint; in __blkdev_direct_IO_simple()
231 bio.bi_private = current; in __blkdev_direct_IO_simple()
232 bio.bi_end_io = blkdev_bio_end_io_simple; in __blkdev_direct_IO_simple()
[all …]
/fs/erofs/
Ddata.c12 static void erofs_readendio(struct bio *bio) in erofs_readendio() argument
15 blk_status_t err = bio->bi_status; in erofs_readendio()
18 bio_for_each_segment_all(bvec, bio, iter_all) { in erofs_readendio()
32 bio_put(bio); in erofs_readendio()
127 static inline struct bio *erofs_read_raw_page(struct bio *bio, in erofs_read_raw_page() argument
147 if (bio && in erofs_read_raw_page()
151 submit_bio(bio); in erofs_read_raw_page()
152 bio = NULL; in erofs_read_raw_page()
155 if (!bio) { in erofs_read_raw_page()
221 bio = bio_alloc(GFP_NOIO, nblocks); in erofs_read_raw_page()
[all …]
/fs/btrfs/
Draid56.c181 static int fail_bio_stripe(struct btrfs_raid_bio *rbio, struct bio *bio);
857 static void rbio_endio_bio_list(struct bio *cur, blk_status_t err) in rbio_endio_bio_list()
859 struct bio *next; in rbio_endio_bio_list()
876 struct bio *cur = bio_list_get(&rbio->bio_list); in rbio_orig_end_io()
877 struct bio *extra; in rbio_orig_end_io()
903 static void raid_write_end_io(struct bio *bio) in raid_write_end_io() argument
905 struct btrfs_raid_bio *rbio = bio->bi_private; in raid_write_end_io()
906 blk_status_t err = bio->bi_status; in raid_write_end_io()
910 fail_bio_stripe(rbio, bio); in raid_write_end_io()
912 bio_put(bio); in raid_write_end_io()
[all …]
Dcompression.c126 static void end_compressed_bio_read(struct bio *bio) in end_compressed_bio_read() argument
128 struct compressed_bio *cb = bio->bi_private; in end_compressed_bio_read()
132 unsigned int mirror = btrfs_io_bio(bio)->mirror_num; in end_compressed_bio_read()
135 if (bio->bi_status) in end_compressed_bio_read()
161 (u64)bio->bi_iter.bi_sector << 9); in end_compressed_bio_read()
193 ASSERT(!bio_flagged(bio, BIO_CLONED)); in end_compressed_bio_read()
204 bio_put(bio); in end_compressed_bio_read()
253 static void end_compressed_bio_write(struct bio *bio) in end_compressed_bio_write() argument
255 struct compressed_bio *cb = bio->bi_private; in end_compressed_bio_write()
260 if (bio->bi_status) in end_compressed_bio_write()
[all …]
Draid56.h33 int raid56_parity_recover(struct btrfs_fs_info *fs_info, struct bio *bio,
36 int raid56_parity_write(struct btrfs_fs_info *fs_info, struct bio *bio,
43 raid56_parity_alloc_scrub_rbio(struct btrfs_fs_info *fs_info, struct bio *bio,
50 raid56_alloc_missing_rbio(struct btrfs_fs_info *fs_info, struct bio *bio,
Dscrub.c87 struct bio *bio; member
241 static void scrub_bio_end_io(struct bio *bio);
252 static void scrub_wr_bio_end_io(struct bio *bio);
553 bio_put(sbio->bio); in scrub_free_ctx()
1391 static void scrub_bio_wait_endio(struct bio *bio) in scrub_bio_wait_endio() argument
1393 complete(bio->bi_private); in scrub_bio_wait_endio()
1397 struct bio *bio, in scrub_submit_raid56_bio_wait() argument
1404 bio->bi_iter.bi_sector = page->logical >> 9; in scrub_submit_raid56_bio_wait()
1405 bio->bi_private = &done; in scrub_submit_raid56_bio_wait()
1406 bio->bi_end_io = scrub_bio_wait_endio; in scrub_submit_raid56_bio_wait()
[all …]
Dextent_io.c119 struct bio *bio; member
148 static int __must_check submit_one_bio(struct bio *bio, int mirror_num, in submit_one_bio() argument
152 struct extent_io_tree *tree = bio->bi_private; in submit_one_bio()
154 bio->bi_private = NULL; in submit_one_bio()
157 ret = tree->ops->submit_bio_hook(tree->private_data, bio, in submit_one_bio()
160 btrfsic_submit_bio(bio); in submit_one_bio()
168 if (epd->bio) { in end_write_bio()
169 epd->bio->bi_status = errno_to_blk_status(ret); in end_write_bio()
170 bio_endio(epd->bio); in end_write_bio()
171 epd->bio = NULL; in end_write_bio()
[all …]
Dcheck-integrity.c157 bio_end_io_t *bio; member
327 struct bio *bio, int *bio_is_patched,
334 static void btrfsic_bio_end_io(struct bio *bp);
403 b->orig_bio_bh_end_io.bio = NULL; in btrfsic_block_init()
1626 struct bio *bio; in btrfsic_read_block() local
1629 bio = btrfs_io_bio_alloc(num_pages - i); in btrfsic_read_block()
1630 bio_set_dev(bio, block_ctx->dev->bdev); in btrfsic_read_block()
1631 bio->bi_iter.bi_sector = dev_bytenr >> 9; in btrfsic_read_block()
1632 bio->bi_opf = REQ_OP_READ; in btrfsic_read_block()
1635 ret = bio_add_page(bio, block_ctx->pagev[j], in btrfsic_read_block()
[all …]
Dvolumes.h22 struct bio *head;
23 struct bio *tail;
128 struct bio *flush_bio;
304 struct bio bio; member
307 static inline struct btrfs_io_bio *btrfs_io_bio(struct bio *bio) in btrfs_io_bio() argument
309 return container_of(bio, struct btrfs_io_bio, bio); in btrfs_io_bio()
332 struct bio *orig_bio;
406 static inline enum btrfs_map_op btrfs_op(struct bio *bio) in btrfs_op() argument
408 switch (bio_op(bio)) { in btrfs_op()
437 blk_status_t btrfs_map_bio(struct btrfs_fs_info *fs_info, struct bio *bio,
/fs/f2fs/
Ddata.c83 struct bio *bio; member
89 static void __read_end_io(struct bio *bio) in __read_end_io() argument
95 bio_for_each_segment_all(bv, bio, iter_all) { in __read_end_io()
99 if (bio->bi_status || PageError(page)) { in __read_end_io()
109 if (bio->bi_private) in __read_end_io()
110 mempool_free(bio->bi_private, bio_post_read_ctx_pool); in __read_end_io()
111 bio_put(bio); in __read_end_io()
121 fscrypt_decrypt_bio(ctx->bio); in decrypt_work()
131 fsverity_verify_bio(ctx->bio); in verity_work()
161 __read_end_io(ctx->bio); in bio_post_read_processing()
[all …]
/fs/xfs/
Dxfs_bio_io.c24 struct bio *bio; in xfs_rw_bdev() local
29 bio = bio_alloc(GFP_KERNEL, bio_max_vecs(left)); in xfs_rw_bdev()
30 bio_set_dev(bio, bdev); in xfs_rw_bdev()
31 bio->bi_iter.bi_sector = sector; in xfs_rw_bdev()
32 bio->bi_opf = op | REQ_META | REQ_SYNC; in xfs_rw_bdev()
39 while (bio_add_page(bio, page, len, off) != len) { in xfs_rw_bdev()
40 struct bio *prev = bio; in xfs_rw_bdev()
42 bio = bio_alloc(GFP_KERNEL, bio_max_vecs(left)); in xfs_rw_bdev()
43 bio_copy_dev(bio, prev); in xfs_rw_bdev()
44 bio->bi_iter.bi_sector = bio_end_sector(prev); in xfs_rw_bdev()
[all …]
Dxfs_aops.c89 struct bio *bio = &ioend->io_inline_bio; in xfs_destroy_ioend() local
90 struct bio *last = ioend->io_bio, *next; in xfs_destroy_ioend()
91 u64 start = bio->bi_iter.bi_sector; in xfs_destroy_ioend()
92 bool quiet = bio_flagged(bio, BIO_QUIET); in xfs_destroy_ioend()
94 for (bio = &ioend->io_inline_bio; bio; bio = next) { in xfs_destroy_ioend()
102 if (bio == last) in xfs_destroy_ioend()
105 next = bio->bi_private; in xfs_destroy_ioend()
108 bio_for_each_segment_all(bvec, bio, iter_all) in xfs_destroy_ioend()
110 bio_put(bio); in xfs_destroy_ioend()
398 struct bio *bio) in xfs_end_bio() argument
[all …]
/fs/crypto/
Dbio.c29 void fscrypt_decrypt_bio(struct bio *bio) in fscrypt_decrypt_bio() argument
34 bio_for_each_segment_all(bv, bio, iter_all) { in fscrypt_decrypt_bio()
51 struct bio *bio; in fscrypt_zeroout_range() local
71 bio = bio_alloc(GFP_NOWAIT, 1); in fscrypt_zeroout_range()
72 if (!bio) { in fscrypt_zeroout_range()
76 fscrypt_set_bio_crypt_ctx(bio, inode, lblk, GFP_NOIO); in fscrypt_zeroout_range()
78 bio_set_dev(bio, inode->i_sb->s_bdev); in fscrypt_zeroout_range()
79 bio->bi_iter.bi_sector = pblk << (blockbits - 9); in fscrypt_zeroout_range()
80 bio_set_op_attrs(bio, REQ_OP_WRITE, 0); in fscrypt_zeroout_range()
81 ret = bio_add_page(bio, ciphertext_page, blocksize, 0); in fscrypt_zeroout_range()
[all …]
Dinline_crypt.c220 void fscrypt_set_bio_crypt_ctx(struct bio *bio, const struct inode *inode, in fscrypt_set_bio_crypt_ctx() argument
227 bio_set_skip_dm_default_key(bio); in fscrypt_set_bio_crypt_ctx()
233 bio_crypt_set_ctx(bio, &ci->ci_key.blk_key->base, dun, gfp_mask); in fscrypt_set_bio_crypt_ctx()
271 void fscrypt_set_bio_crypt_ctx_bh(struct bio *bio, in fscrypt_set_bio_crypt_ctx_bh() argument
279 fscrypt_set_bio_crypt_ctx(bio, inode, first_lblk, gfp_mask); in fscrypt_set_bio_crypt_ctx_bh()
303 bool fscrypt_mergeable_bio(struct bio *bio, const struct inode *inode, in fscrypt_mergeable_bio() argument
306 const struct bio_crypt_ctx *bc = bio->bi_crypt_context; in fscrypt_mergeable_bio()
311 if (bio_should_skip_dm_default_key(bio) != in fscrypt_mergeable_bio()
326 return bio_crypt_dun_is_contiguous(bc, bio->bi_iter.bi_size, next_dun); in fscrypt_mergeable_bio()
340 bool fscrypt_mergeable_bio_bh(struct bio *bio, in fscrypt_mergeable_bio_bh() argument
[all …]
/fs/nfs/blocklayout/
Dblocklayout.c104 static struct bio *
105 bl_submit_bio(struct bio *bio) in bl_submit_bio() argument
107 if (bio) { in bl_submit_bio()
108 get_parallel(bio->bi_private); in bl_submit_bio()
110 bio_op(bio) == READ ? "read" : "write", in bl_submit_bio()
111 bio->bi_iter.bi_size, in bl_submit_bio()
112 (unsigned long long)bio->bi_iter.bi_sector); in bl_submit_bio()
113 submit_bio(bio); in bl_submit_bio()
118 static struct bio *
122 struct bio *bio; in bl_alloc_init_bio() local
[all …]
/fs/iomap/
Ddirect-io.c63 struct bio *bio) in iomap_dio_submit_bio() argument
68 bio_set_polled(bio, dio->iocb); in iomap_dio_submit_bio()
71 dio->submit.cookie = submit_bio(bio); in iomap_dio_submit_bio()
147 static void iomap_dio_bio_end_io(struct bio *bio) in iomap_dio_bio_end_io() argument
149 struct iomap_dio *dio = bio->bi_private; in iomap_dio_bio_end_io()
152 if (bio->bi_status) in iomap_dio_bio_end_io()
153 iomap_dio_set_error(dio, blk_status_to_errno(bio->bi_status)); in iomap_dio_bio_end_io()
171 bio_check_pages_dirty(bio); in iomap_dio_bio_end_io()
173 bio_release_pages(bio, false); in iomap_dio_bio_end_io()
174 bio_put(bio); in iomap_dio_bio_end_io()
[all …]
Dbuffered-io.c167 iomap_read_end_io(struct bio *bio) in iomap_read_end_io() argument
169 int error = blk_status_to_errno(bio->bi_status); in iomap_read_end_io()
173 bio_for_each_segment_all(bvec, bio, iter_all) in iomap_read_end_io()
175 bio_put(bio); in iomap_read_end_io()
182 struct bio *bio; member
241 if (ctx->bio && bio_end_sector(ctx->bio) == sector) in iomap_readpage_actor()
245 __bio_try_merge_page(ctx->bio, page, plen, poff, &same_page)) { in iomap_readpage_actor()
259 if (!ctx->bio || !is_contig || bio_full(ctx->bio, plen)) { in iomap_readpage_actor()
263 if (ctx->bio) in iomap_readpage_actor()
264 submit_bio(ctx->bio); in iomap_readpage_actor()
[all …]
/fs/nilfs2/
Dsegbuf.c22 struct bio *bio; member
328 static void nilfs_end_bio_write(struct bio *bio) in nilfs_end_bio_write() argument
330 struct nilfs_segment_buffer *segbuf = bio->bi_private; in nilfs_end_bio_write()
332 if (bio->bi_status) in nilfs_end_bio_write()
335 bio_put(bio); in nilfs_end_bio_write()
343 struct bio *bio = wi->bio; in nilfs_segbuf_submit_bio() local
351 bio_put(bio); in nilfs_segbuf_submit_bio()
357 bio->bi_end_io = nilfs_end_bio_write; in nilfs_segbuf_submit_bio()
358 bio->bi_private = segbuf; in nilfs_segbuf_submit_bio()
359 bio_set_op_attrs(bio, mode, mode_flags); in nilfs_segbuf_submit_bio()
[all …]
/fs/jfs/
Djfs_metapage.c266 static void metapage_read_end_io(struct bio *bio) in metapage_read_end_io() argument
268 struct page *page = bio->bi_private; in metapage_read_end_io()
270 if (bio->bi_status) { in metapage_read_end_io()
276 bio_put(bio); in metapage_read_end_io()
321 static void metapage_write_end_io(struct bio *bio) in metapage_write_end_io() argument
323 struct page *page = bio->bi_private; in metapage_write_end_io()
327 if (bio->bi_status) { in metapage_write_end_io()
332 bio_put(bio); in metapage_write_end_io()
337 struct bio *bio = NULL; in metapage_writepage() local
382 if (bio) { in metapage_writepage()
[all …]
/fs/gfs2/
Dlops.c203 static void gfs2_end_log_write(struct bio *bio) in gfs2_end_log_write() argument
205 struct gfs2_sbd *sdp = bio->bi_private; in gfs2_end_log_write()
210 if (bio->bi_status) { in gfs2_end_log_write()
212 bio->bi_status, sdp->sd_jdesc->jd_jid); in gfs2_end_log_write()
216 bio_for_each_segment_all(bvec, bio, iter_all) { in gfs2_end_log_write()
219 gfs2_end_log_write_bh(sdp, bvec, bio->bi_status); in gfs2_end_log_write()
224 bio_put(bio); in gfs2_end_log_write()
238 void gfs2_log_submit_bio(struct bio **biop, int opf) in gfs2_log_submit_bio()
240 struct bio *bio = *biop; in gfs2_log_submit_bio() local
241 if (bio) { in gfs2_log_submit_bio()
[all …]
Dmeta_io.c186 static void gfs2_meta_read_endio(struct bio *bio) in gfs2_meta_read_endio() argument
191 bio_for_each_segment_all(bvec, bio, iter_all) { in gfs2_meta_read_endio()
201 bh->b_end_io(bh, !bio->bi_status); in gfs2_meta_read_endio()
205 bio_put(bio); in gfs2_meta_read_endio()
217 struct bio *bio; in gfs2_submit_bhs() local
219 bio = bio_alloc(GFP_NOIO, num); in gfs2_submit_bhs()
220 bio->bi_iter.bi_sector = bh->b_blocknr * (bh->b_size >> 9); in gfs2_submit_bhs()
221 bio_set_dev(bio, bh->b_bdev); in gfs2_submit_bhs()
224 if (!bio_add_page(bio, bh->b_page, bh->b_size, bh_offset(bh))) { in gfs2_submit_bhs()
225 BUG_ON(bio->bi_iter.bi_size == 0); in gfs2_submit_bhs()
[all …]

123