Lines Matching refs:imap
278 struct xfs_bmbt_irec *imap, in xfs_map_blocks() argument
311 imap, &nimaps, bmapi_flags); in xfs_map_blocks()
318 (!nimaps || isnullstartblock(imap->br_startblock))) { in xfs_map_blocks()
319 error = xfs_iomap_write_allocate(ip, offset, imap); in xfs_map_blocks()
321 trace_xfs_map_blocks_alloc(ip, offset, count, type, imap); in xfs_map_blocks()
328 ASSERT(imap->br_startblock != HOLESTARTBLOCK); in xfs_map_blocks()
329 ASSERT(imap->br_startblock != DELAYSTARTBLOCK); in xfs_map_blocks()
333 trace_xfs_map_blocks_found(ip, offset, count, type, imap); in xfs_map_blocks()
340 struct xfs_bmbt_irec *imap, in xfs_imap_valid() argument
345 return offset >= imap->br_startoff && in xfs_imap_valid()
346 offset < imap->br_startoff + imap->br_blockcount; in xfs_imap_valid()
597 struct xfs_bmbt_irec *imap, in xfs_map_buffer() argument
602 xfs_off_t iomap_offset = XFS_FSB_TO_B(m, imap->br_startoff); in xfs_map_buffer()
603 xfs_daddr_t iomap_bn = xfs_fsb_to_db(XFS_I(inode), imap->br_startblock); in xfs_map_buffer()
605 ASSERT(imap->br_startblock != HOLESTARTBLOCK); in xfs_map_buffer()
606 ASSERT(imap->br_startblock != DELAYSTARTBLOCK); in xfs_map_buffer()
621 struct xfs_bmbt_irec *imap, in xfs_map_at_offset() argument
624 ASSERT(imap->br_startblock != HOLESTARTBLOCK); in xfs_map_at_offset()
625 ASSERT(imap->br_startblock != DELAYSTARTBLOCK); in xfs_map_at_offset()
627 xfs_map_buffer(inode, bh, imap, offset); in xfs_map_at_offset()
687 struct xfs_bmbt_irec *imap, in xfs_convert_page() argument
743 if (!xfs_imap_valid(inode, imap, end_offset)) in xfs_convert_page()
785 ASSERT(xfs_imap_valid(inode, imap, offset)); in xfs_convert_page()
789 xfs_map_at_offset(inode, bh, imap, offset); in xfs_convert_page()
826 struct xfs_bmbt_irec *imap, in xfs_cluster_write() argument
843 imap, ioendp, wbc); in xfs_cluster_write()
944 struct xfs_bmbt_irec imap; in xfs_vm_writepage() local
1104 imap_valid = xfs_imap_valid(inode, &imap, offset); in xfs_vm_writepage()
1115 err = xfs_map_blocks(inode, offset, &imap, type, in xfs_vm_writepage()
1119 imap_valid = xfs_imap_valid(inode, &imap, offset); in xfs_vm_writepage()
1124 xfs_map_at_offset(inode, bh, &imap, offset); in xfs_vm_writepage()
1154 end_index = imap.br_startoff + imap.br_blockcount; in xfs_vm_writepage()
1166 xfs_cluster_write(inode, page->index + 1, &imap, &ioend, in xfs_vm_writepage()
1262 struct xfs_bmbt_irec *imap, in xfs_map_direct() argument
1269 if (ISUNWRITTEN(imap)) in xfs_map_direct()
1274 trace_xfs_gbmap_direct(XFS_I(inode), offset, size, type, imap); in xfs_map_direct()
1288 imap); in xfs_map_direct()
1299 imap); in xfs_map_direct()
1302 imap); in xfs_map_direct()
1322 struct xfs_bmbt_irec *imap, in xfs_map_trim_size() argument
1328 mapping_size = imap->br_startoff + imap->br_blockcount - iblock; in xfs_map_trim_size()
1359 struct xfs_bmbt_irec imap; in __xfs_get_blocks() local
1396 &imap, &nimaps, XFS_BMAPI_ENTIRE); in __xfs_get_blocks()
1402 (imap.br_startblock == HOLESTARTBLOCK || in __xfs_get_blocks()
1403 imap.br_startblock == DELAYSTARTBLOCK))) { in __xfs_get_blocks()
1413 &imap, nimaps); in __xfs_get_blocks()
1426 if (nimaps && imap.br_startblock == HOLESTARTBLOCK) in __xfs_get_blocks()
1428 error = xfs_iomap_write_delay(ip, offset, size, &imap); in __xfs_get_blocks()
1435 ISUNWRITTEN(&imap) ? XFS_IO_UNWRITTEN in __xfs_get_blocks()
1436 : XFS_IO_DELALLOC, &imap); in __xfs_get_blocks()
1439 ISUNWRITTEN(&imap) ? XFS_IO_UNWRITTEN in __xfs_get_blocks()
1440 : XFS_IO_OVERWRITE, &imap); in __xfs_get_blocks()
1450 &imap, offset, size); in __xfs_get_blocks()
1456 if (imap.br_startblock != HOLESTARTBLOCK && in __xfs_get_blocks()
1457 imap.br_startblock != DELAYSTARTBLOCK && in __xfs_get_blocks()
1458 (create || !ISUNWRITTEN(&imap))) { in __xfs_get_blocks()
1459 xfs_map_buffer(inode, bh_result, &imap, offset); in __xfs_get_blocks()
1460 if (ISUNWRITTEN(&imap)) in __xfs_get_blocks()
1464 xfs_map_direct(inode, bh_result, &imap, offset); in __xfs_get_blocks()
1485 (new || ISUNWRITTEN(&imap)))) in __xfs_get_blocks()
1488 if (imap.br_startblock == DELAYSTARTBLOCK) { in __xfs_get_blocks()