Lines Matching refs:map_bh

119 	struct buffer_head map_bh;  member
140 struct buffer_head *map_bh = &args->map_bh; in do_mpage_readpage() local
176 nblocks = map_bh->b_size >> blkbits; in do_mpage_readpage()
177 if (buffer_mapped(map_bh) && in do_mpage_readpage()
185 clear_buffer_mapped(map_bh); in do_mpage_readpage()
190 blocks[page_block] = map_bh->b_blocknr + map_offset + in do_mpage_readpage()
195 bdev = map_bh->b_bdev; in do_mpage_readpage()
201 map_bh->b_page = &folio->page; in do_mpage_readpage()
203 map_bh->b_state = 0; in do_mpage_readpage()
204 map_bh->b_size = 0; in do_mpage_readpage()
207 map_bh->b_size = (last_block-block_in_file) << blkbits; in do_mpage_readpage()
208 if (args->get_block(inode, block_in_file, map_bh, 0)) in do_mpage_readpage()
213 if (!buffer_mapped(map_bh)) { in do_mpage_readpage()
228 if (buffer_uptodate(map_bh)) { in do_mpage_readpage()
229 map_buffer_to_folio(folio, map_bh, page_block); in do_mpage_readpage()
237 if (page_block && blocks[page_block-1] != map_bh->b_blocknr-1) in do_mpage_readpage()
239 nblocks = map_bh->b_size >> blkbits; in do_mpage_readpage()
242 clear_buffer_mapped(map_bh); in do_mpage_readpage()
246 blocks[page_block] = map_bh->b_blocknr+relative_block; in do_mpage_readpage()
250 bdev = map_bh->b_bdev; in do_mpage_readpage()
291 nblocks = map_bh->b_size >> blkbits; in do_mpage_readpage()
292 if ((buffer_boundary(map_bh) && relative_block == nblocks) || in do_mpage_readpage()
468 struct buffer_head map_bh; in __mpage_writepage() local
528 map_bh.b_page = page; in __mpage_writepage()
531 map_bh.b_state = 0; in __mpage_writepage()
532 map_bh.b_size = 1 << blkbits; in __mpage_writepage()
533 if (mpd->get_block(inode, block_in_file, &map_bh, 1)) in __mpage_writepage()
535 if (buffer_new(&map_bh)) in __mpage_writepage()
536 clean_bdev_bh_alias(&map_bh); in __mpage_writepage()
537 if (buffer_boundary(&map_bh)) { in __mpage_writepage()
538 boundary_block = map_bh.b_blocknr; in __mpage_writepage()
539 boundary_bdev = map_bh.b_bdev; in __mpage_writepage()
542 if (map_bh.b_blocknr != blocks[page_block-1] + 1) in __mpage_writepage()
545 blocks[page_block++] = map_bh.b_blocknr; in __mpage_writepage()
546 boundary = buffer_boundary(&map_bh); in __mpage_writepage()
547 bdev = map_bh.b_bdev; in __mpage_writepage()