Lines Matching refs:dp
62 struct xfs_inode *dp, in xfs_dir3_leafn_check() argument
68 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &leafhdr, leaf); in xfs_dir3_leafn_check()
77 return xfs_dir3_leaf_check_int(dp->i_mount, &leafhdr, leaf, false); in xfs_dir3_leafn_check()
82 struct xfs_inode *dp, in xfs_dir3_leaf_check() argument
87 fa = xfs_dir3_leafn_check(dp, bp); in xfs_dir3_leaf_check()
90 xfs_corruption_error(__func__, XFS_ERRLEVEL_LOW, dp->i_mount, in xfs_dir3_leaf_check()
96 #define xfs_dir3_leaf_check(dp, bp) argument
216 struct xfs_inode *dp, in __xfs_dir3_free_read() argument
225 err = xfs_da_read_buf(tp, dp, fbno, flags, bpp, XFS_DATA_FORK, in __xfs_dir3_free_read()
236 xfs_dirattr_mark_sick(dp, XFS_DATA_FORK); in __xfs_dir3_free_read()
302 struct xfs_inode *dp, in xfs_dir2_free_read() argument
307 return __xfs_dir3_free_read(tp, dp, owner, fbno, 0, bpp); in xfs_dir2_free_read()
313 struct xfs_inode *dp, in xfs_dir2_free_try_read() argument
318 return __xfs_dir3_free_read(tp, dp, owner, fbno, XFS_DABUF_MAP_HOLE_OK, in xfs_dir2_free_try_read()
329 struct xfs_inode *dp = args->dp; in xfs_dir3_free_get_buf() local
330 struct xfs_mount *mp = dp->i_mount; in xfs_dir3_free_get_buf()
335 error = xfs_da_get_buf(tp, dp, xfs_dir2_db_to_da(args->geo, fbno), in xfs_dir3_free_get_buf()
415 xfs_inode_t *dp; /* incore directory inode */ in xfs_dir2_leaf_to_node() local
430 dp = args->dp; in xfs_dir2_leaf_to_node()
446 xfs_dir2_free_hdr_from_disk(dp->i_mount, &freehdr, fbp->b_addr); in xfs_dir2_leaf_to_node()
450 (uint)dp->i_disk_size / args->geo->blksize) { in xfs_dir2_leaf_to_node()
474 xfs_dir2_free_hdr_to_disk(dp->i_mount, fbp->b_addr, &freehdr); in xfs_dir2_leaf_to_node()
491 xfs_dir3_leaf_check(dp, lbp); in xfs_dir2_leaf_to_node()
506 struct xfs_inode *dp = args->dp; in xfs_dir2_leafn_add() local
518 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &leafhdr, leaf); in xfs_dir2_leafn_add()
576 xfs_dir2_leaf_hdr_to_disk(dp->i_mount, leaf, &leafhdr); in xfs_dir2_leafn_add()
579 xfs_dir3_leaf_check(dp, bp); in xfs_dir2_leafn_add()
586 struct xfs_inode *dp, in xfs_dir2_free_hdr_check() argument
592 xfs_dir2_free_hdr_from_disk(dp->i_mount, &hdr, bp->b_addr); in xfs_dir2_free_hdr_check()
594 ASSERT((hdr.firstdb % dp->i_mount->m_dir_geo->free_max_bests) == 0); in xfs_dir2_free_hdr_check()
599 #define xfs_dir2_free_hdr_check(dp, bp, db) argument
608 struct xfs_inode *dp, in xfs_dir2_leaf_lasthash() argument
614 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &leafhdr, bp->b_addr); in xfs_dir2_leaf_lasthash()
642 xfs_inode_t *dp; /* incore directory inode */ in xfs_dir2_leafn_lookup_for_addname() local
656 dp = args->dp; in xfs_dir2_leafn_lookup_for_addname()
658 mp = dp->i_mount; in xfs_dir2_leafn_lookup_for_addname()
662 xfs_dir3_leaf_check(dp, bp); in xfs_dir2_leafn_lookup_for_addname()
724 error = xfs_dir2_free_read(tp, dp, args->owner, in xfs_dir2_leafn_lookup_for_addname()
732 xfs_dir2_free_hdr_check(dp, curbp, curdb); in xfs_dir2_leafn_lookup_for_addname()
796 xfs_inode_t *dp; /* incore directory inode */ in xfs_dir2_leafn_lookup_for_entry() local
807 dp = args->dp; in xfs_dir2_leafn_lookup_for_entry()
809 mp = dp->i_mount; in xfs_dir2_leafn_lookup_for_entry()
813 xfs_dir3_leaf_check(dp, bp); in xfs_dir2_leafn_lookup_for_entry()
870 error = xfs_dir3_data_read(tp, dp, args->owner, in xfs_dir2_leafn_lookup_for_entry()
877 xfs_dir3_data_check(dp, curbp); in xfs_dir2_leafn_lookup_for_entry()
1039 struct xfs_inode *dp, in xfs_dir2_leafn_order() argument
1050 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &hdr1, leaf1); in xfs_dir2_leafn_order()
1051 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &hdr2, leaf2); in xfs_dir2_leafn_order()
1091 struct xfs_inode *dp = state->args->dp; in xfs_dir2_leafn_rebalance() local
1097 swap_blocks = xfs_dir2_leafn_order(dp, blk1->bp, blk2->bp); in xfs_dir2_leafn_rebalance()
1103 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &hdr1, leaf1); in xfs_dir2_leafn_rebalance()
1104 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &hdr2, leaf2); in xfs_dir2_leafn_rebalance()
1152 xfs_dir2_leaf_hdr_to_disk(dp->i_mount, leaf1, &hdr1); in xfs_dir2_leafn_rebalance()
1153 xfs_dir2_leaf_hdr_to_disk(dp->i_mount, leaf2, &hdr2); in xfs_dir2_leafn_rebalance()
1157 xfs_dir3_leaf_check(dp, blk1->bp); in xfs_dir2_leafn_rebalance()
1158 xfs_dir3_leaf_check(dp, blk2->bp); in xfs_dir2_leafn_rebalance()
1182 xfs_alert(dp->i_mount, in xfs_dir2_leafn_rebalance()
1200 struct xfs_inode *dp = args->dp; in xfs_dir3_data_block_free() local
1202 xfs_dir2_free_hdr_from_disk(dp->i_mount, &freehdr, free); in xfs_dir3_data_block_free()
1236 xfs_dir2_free_hdr_to_disk(dp->i_mount, free, &freehdr); in xfs_dir3_data_block_free()
1283 xfs_inode_t *dp; /* incore directory inode */ in xfs_dir2_leafn_remove() local
1296 dp = args->dp; in xfs_dir2_leafn_remove()
1299 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &leafhdr, leaf); in xfs_dir2_leafn_remove()
1319 xfs_dir2_leaf_hdr_to_disk(dp->i_mount, leaf, &leafhdr); in xfs_dir2_leafn_remove()
1332 bf = xfs_dir2_data_bestfree_p(dp->i_mount, hdr); in xfs_dir2_leafn_remove()
1336 xfs_dir2_data_entsize(dp->i_mount, dep->namelen), &needlog, in xfs_dir2_leafn_remove()
1343 xfs_dir2_data_freescan(dp->i_mount, hdr, &needlog); in xfs_dir2_leafn_remove()
1346 xfs_dir3_data_check(dp, dbp); in xfs_dir2_leafn_remove()
1363 error = xfs_dir2_free_read(tp, dp, args->owner, in xfs_dir2_leafn_remove()
1372 xfs_dir2_free_hdr_from_disk(dp->i_mount, &freehdr, free); in xfs_dir2_leafn_remove()
1413 xfs_dir3_leaf_check(dp, bp); in xfs_dir2_leafn_remove()
1436 struct xfs_inode *dp; in xfs_dir2_leafn_split() local
1442 dp = args->dp; in xfs_dir2_leafn_split()
1477 oldblk->hashval = xfs_dir2_leaf_lasthash(dp, oldblk->bp, NULL); in xfs_dir2_leafn_split()
1478 newblk->hashval = xfs_dir2_leaf_lasthash(dp, newblk->bp, NULL); in xfs_dir2_leafn_split()
1479 xfs_dir3_leaf_check(dp, oldblk->bp); in xfs_dir2_leafn_split()
1480 xfs_dir3_leaf_check(dp, newblk->bp); in xfs_dir2_leafn_split()
1510 struct xfs_inode *dp = state->args->dp; in xfs_dir2_leafn_toosmall() local
1519 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &leafhdr, leaf); in xfs_dir2_leafn_toosmall()
1521 xfs_dir3_leaf_check(dp, blk->bp); in xfs_dir2_leafn_toosmall()
1569 error = xfs_dir3_leafn_read(state->args->trans, dp, in xfs_dir2_leafn_toosmall()
1582 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &hdr2, leaf); in xfs_dir2_leafn_toosmall()
1637 struct xfs_inode *dp = state->args->dp; in xfs_dir2_leafn_unbalance() local
1645 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &savehdr, save_leaf); in xfs_dir2_leafn_unbalance()
1646 xfs_dir2_leaf_hdr_from_disk(dp->i_mount, &drophdr, drop_leaf); in xfs_dir2_leafn_unbalance()
1663 if (xfs_dir2_leafn_order(dp, save_blk->bp, drop_blk->bp)) in xfs_dir2_leafn_unbalance()
1674 xfs_dir2_leaf_hdr_to_disk(dp->i_mount, save_leaf, &savehdr); in xfs_dir2_leafn_unbalance()
1675 xfs_dir2_leaf_hdr_to_disk(dp->i_mount, drop_leaf, &drophdr); in xfs_dir2_leafn_unbalance()
1679 xfs_dir3_leaf_check(dp, save_blk->bp); in xfs_dir2_leafn_unbalance()
1680 xfs_dir3_leaf_check(dp, drop_blk->bp); in xfs_dir2_leafn_unbalance()
1697 struct xfs_inode *dp = args->dp; in xfs_dir2_node_add_datablk() local
1699 struct xfs_mount *mp = dp->i_mount; in xfs_dir2_node_add_datablk()
1723 error = xfs_dir2_free_try_read(tp, dp, args->owner, in xfs_dir2_node_add_datablk()
1742 __func__, (unsigned long long)dp->i_ino, in xfs_dir2_node_add_datablk()
1810 struct xfs_inode *dp = args->dp; in xfs_dir2_node_find_freeblk() local
1830 xfs_dir2_free_hdr_from_disk(dp->i_mount, hdr, fbp->b_addr); in xfs_dir2_node_find_freeblk()
1854 error = xfs_bmap_last_offset(dp, &fo, XFS_DATA_FORK); in xfs_dir2_node_find_freeblk()
1870 error = xfs_dir2_free_try_read(tp, dp, args->owner, in xfs_dir2_node_find_freeblk()
1878 xfs_dir2_free_hdr_from_disk(dp->i_mount, hdr, fbp->b_addr); in xfs_dir2_node_find_freeblk()
1915 struct xfs_inode *dp = args->dp; in xfs_dir2_node_addname_int() local
1929 length = xfs_dir2_data_entsize(dp->i_mount, args->namelen); in xfs_dir2_node_addname_int()
1956 error = xfs_dir3_data_read(tp, dp, args->owner, in xfs_dir2_node_addname_int()
1964 bf = xfs_dir2_data_bestfree_p(dp->i_mount, hdr); in xfs_dir2_node_addname_int()
1985 xfs_dir2_data_put_ftype(dp->i_mount, dep, args->filetype); in xfs_dir2_node_addname_int()
1986 tagp = xfs_dir2_data_entry_tag_p(dp->i_mount, dep); in xfs_dir2_node_addname_int()
1992 xfs_dir2_data_freescan(dp->i_mount, hdr, &needlog); in xfs_dir2_node_addname_int()
2295 xfs_inode_t *dp; /* incore directory inode */ in xfs_dir2_node_trim_free() local
2301 dp = args->dp; in xfs_dir2_node_trim_free()
2309 error = xfs_dir2_free_try_read(tp, dp, args->owner, fo, &bp); in xfs_dir2_node_trim_free()
2319 xfs_dir2_free_hdr_from_disk(dp->i_mount, &freehdr, free); in xfs_dir2_node_trim_free()