Lines Matching refs:args
302 struct xfs_da_args *args, in xfs_da3_node_create() argument
309 struct xfs_trans *tp = args->trans; in xfs_da3_node_create()
314 struct xfs_inode *dp = args->dp; in xfs_da3_node_create()
316 trace_xfs_da_node_create(args); in xfs_da3_node_create()
332 hdr3->info.owner = cpu_to_be64(args->dp->i_ino); in xfs_da3_node_create()
365 trace_xfs_da_split(state->args); in xfs_da3_split()
405 trace_xfs_attr_leaf_split_before(state->args); in xfs_da3_split()
410 trace_xfs_attr_leaf_split_after(state->args); in xfs_da3_split()
480 xfs_trans_log_buf(state->args->trans, bp, in xfs_da3_split()
494 xfs_trans_log_buf(state->args->trans, bp, in xfs_da3_split()
517 struct xfs_da_args *args; in xfs_da3_root_split() local
527 trace_xfs_da_root_split(state->args); in xfs_da3_root_split()
533 args = state->args; in xfs_da3_root_split()
534 error = xfs_da_grow_inode(args, &blkno); in xfs_da3_root_split()
538 dp = args->dp; in xfs_da3_root_split()
539 tp = args->trans; in xfs_da3_root_split()
540 error = xfs_da_get_buf(tp, dp, blkno, -1, &bp, args->whichfork); in xfs_da3_root_split()
602 error = xfs_da3_node_create(args, in xfs_da3_root_split()
603 (args->whichfork == XFS_DATA_FORK) ? args->geo->leafblk : 0, in xfs_da3_root_split()
604 level + 1, &bp, args->whichfork); in xfs_da3_root_split()
621 ASSERT(blk1->blkno >= args->geo->leafblk && in xfs_da3_root_split()
622 blk1->blkno < args->geo->freeblk); in xfs_da3_root_split()
623 ASSERT(blk2->blkno >= args->geo->leafblk && in xfs_da3_root_split()
624 blk2->blkno < args->geo->freeblk); in xfs_da3_root_split()
653 struct xfs_inode *dp = state->args->dp; in xfs_da3_node_split()
655 trace_xfs_da_node_split(state->args); in xfs_da3_node_split()
663 useextra = state->extravalid && state->args->whichfork == XFS_ATTR_FORK; in xfs_da3_node_split()
668 if (nodehdr.count + newcount > state->args->geo->node_ents) { in xfs_da3_node_split()
673 error = xfs_da_grow_inode(state->args, &blkno); in xfs_da3_node_split()
677 error = xfs_da3_node_create(state->args, blkno, treelevel, in xfs_da3_node_split()
678 &newblk->bp, state->args->whichfork); in xfs_da3_node_split()
754 struct xfs_inode *dp = state->args->dp; in xfs_da3_node_rebalance()
756 trace_xfs_da_node_rebalance(state->args); in xfs_da3_node_rebalance()
786 tp = state->args->trans; in xfs_da3_node_rebalance()
888 struct xfs_inode *dp = state->args->dp; in xfs_da3_node_add()
890 trace_xfs_da_node_add(state->args); in xfs_da3_node_add()
898 if (state->args->whichfork == XFS_DATA_FORK) in xfs_da3_node_add()
899 ASSERT(newblk->blkno >= state->args->geo->leafblk && in xfs_da3_node_add()
900 newblk->blkno < state->args->geo->freeblk); in xfs_da3_node_add()
912 xfs_trans_log_buf(state->args->trans, oldblk->bp, in xfs_da3_node_add()
918 xfs_trans_log_buf(state->args->trans, oldblk->bp, in xfs_da3_node_add()
944 trace_xfs_da_join(state->args); in xfs_da3_join()
1001 error = xfs_da_shrink_inode(state->args, drop_blk->blkno, in xfs_da3_join()
1050 struct xfs_da_args *args; in xfs_da3_root_join() local
1056 struct xfs_inode *dp = state->args->dp; in xfs_da3_root_join()
1058 trace_xfs_da_root_join(state->args); in xfs_da3_root_join()
1062 args = state->args; in xfs_da3_root_join()
1081 error = xfs_da3_node_read(args->trans, dp, child, -1, &bp, in xfs_da3_root_join()
1082 args->whichfork); in xfs_da3_root_join()
1094 memcpy(root_blk->bp->b_addr, bp->b_addr, args->geo->blksize); in xfs_da3_root_join()
1101 xfs_trans_log_buf(args->trans, root_blk->bp, 0, in xfs_da3_root_join()
1102 args->geo->blksize - 1); in xfs_da3_root_join()
1103 error = xfs_da_shrink_inode(args, child, bp); in xfs_da3_root_join()
1132 struct xfs_inode *dp = state->args->dp; in xfs_da3_node_toosmall()
1134 trace_xfs_da_node_toosmall(state->args); in xfs_da3_node_toosmall()
1145 if (nodehdr.count > (state->args->geo->node_ents >> 1)) { in xfs_da3_node_toosmall()
1182 count = state->args->geo->node_ents; in xfs_da3_node_toosmall()
1183 count -= state->args->geo->node_ents >> 2; in xfs_da3_node_toosmall()
1196 error = xfs_da3_node_read(state->args->trans, dp, in xfs_da3_node_toosmall()
1197 blkno, -1, &bp, state->args->whichfork); in xfs_da3_node_toosmall()
1203 xfs_trans_brelse(state->args->trans, bp); in xfs_da3_node_toosmall()
1273 struct xfs_inode *dp = state->args->dp; in xfs_da3_fixhashpath()
1275 trace_xfs_da_fixhashpath(state->args); in xfs_da3_fixhashpath()
1306 xfs_trans_log_buf(state->args->trans, blk->bp, in xfs_da3_fixhashpath()
1327 struct xfs_inode *dp = state->args->dp; in xfs_da3_node_remove()
1329 trace_xfs_da_node_remove(state->args); in xfs_da3_node_remove()
1345 xfs_trans_log_buf(state->args->trans, drop_blk->bp, in xfs_da3_node_remove()
1350 xfs_trans_log_buf(state->args->trans, drop_blk->bp, in xfs_da3_node_remove()
1354 xfs_trans_log_buf(state->args->trans, drop_blk->bp, in xfs_da3_node_remove()
1382 struct xfs_inode *dp = state->args->dp; in xfs_da3_node_unbalance()
1384 trace_xfs_da_node_unbalance(state->args); in xfs_da3_node_unbalance()
1392 tp = state->args->trans; in xfs_da3_node_unbalance()
1461 struct xfs_da_args *args; in xfs_da3_node_lookup_int() local
1470 struct xfs_inode *dp = state->args->dp; in xfs_da3_node_lookup_int()
1472 args = state->args; in xfs_da3_node_lookup_int()
1478 blkno = (args->whichfork == XFS_DATA_FORK)? args->geo->leafblk : 0; in xfs_da3_node_lookup_int()
1486 error = xfs_da3_node_read(args->trans, args->dp, blkno, in xfs_da3_node_lookup_int()
1487 -1, &blk->bp, args->whichfork); in xfs_da3_node_lookup_int()
1506 blk->hashval = xfs_dir2_leafn_lasthash(args->dp, in xfs_da3_node_lookup_int()
1528 hashval = args->hashval; in xfs_da3_node_lookup_int()
1576 retval = xfs_dir2_leafn_lookup_int(blk->bp, args, in xfs_da3_node_lookup_int()
1579 retval = xfs_attr3_leaf_lookup_int(blk->bp, args); in xfs_da3_node_lookup_int()
1580 blk->index = args->index; in xfs_da3_node_lookup_int()
1581 args->blkno = blk->blkno; in xfs_da3_node_lookup_int()
1587 (blk->hashval == args->hashval)) { in xfs_da3_node_lookup_int()
1653 struct xfs_da_args *args; in xfs_da3_blk_link() local
1657 struct xfs_inode *dp = state->args->dp; in xfs_da3_blk_link()
1662 args = state->args; in xfs_da3_blk_link()
1663 ASSERT(args != NULL); in xfs_da3_blk_link()
1689 trace_xfs_da_link_before(args); in xfs_da3_blk_link()
1693 error = xfs_da3_node_read(args->trans, dp, in xfs_da3_blk_link()
1695 -1, &bp, args->whichfork); in xfs_da3_blk_link()
1703 xfs_trans_log_buf(args->trans, bp, 0, sizeof(*tmp_info)-1); in xfs_da3_blk_link()
1710 trace_xfs_da_link_after(args); in xfs_da3_blk_link()
1714 error = xfs_da3_node_read(args->trans, dp, in xfs_da3_blk_link()
1716 -1, &bp, args->whichfork); in xfs_da3_blk_link()
1724 xfs_trans_log_buf(args->trans, bp, 0, sizeof(*tmp_info)-1); in xfs_da3_blk_link()
1729 xfs_trans_log_buf(args->trans, old_blk->bp, 0, sizeof(*tmp_info) - 1); in xfs_da3_blk_link()
1730 xfs_trans_log_buf(args->trans, new_blk->bp, 0, sizeof(*tmp_info) - 1); in xfs_da3_blk_link()
1746 struct xfs_da_args *args; in xfs_da3_blk_unlink() local
1753 args = state->args; in xfs_da3_blk_unlink()
1754 ASSERT(args != NULL); in xfs_da3_blk_unlink()
1770 trace_xfs_da_unlink_back(args); in xfs_da3_blk_unlink()
1773 error = xfs_da3_node_read(args->trans, args->dp, in xfs_da3_blk_unlink()
1775 -1, &bp, args->whichfork); in xfs_da3_blk_unlink()
1783 xfs_trans_log_buf(args->trans, bp, 0, in xfs_da3_blk_unlink()
1787 trace_xfs_da_unlink_forward(args); in xfs_da3_blk_unlink()
1790 error = xfs_da3_node_read(args->trans, args->dp, in xfs_da3_blk_unlink()
1792 -1, &bp, args->whichfork); in xfs_da3_blk_unlink()
1800 xfs_trans_log_buf(args->trans, bp, 0, in xfs_da3_blk_unlink()
1805 xfs_trans_log_buf(args->trans, save_blk->bp, 0, sizeof(*save_info) - 1); in xfs_da3_blk_unlink()
1828 struct xfs_da_args *args; in xfs_da3_path_shift() local
1835 struct xfs_inode *dp = state->args->dp; in xfs_da3_path_shift()
1837 trace_xfs_da_path_shift(state->args); in xfs_da3_path_shift()
1844 args = state->args; in xfs_da3_path_shift()
1845 ASSERT(args != NULL); in xfs_da3_path_shift()
1866 ASSERT(args->op_flags & XFS_DA_OP_OKNOENT); in xfs_da3_path_shift()
1878 error = xfs_da3_node_read(args->trans, dp, blkno, -1, &bp, in xfs_da3_path_shift()
1879 args->whichfork); in xfs_da3_path_shift()
1890 xfs_trans_brelse(args->trans, blk->bp); in xfs_da3_path_shift()
1933 blk->hashval = xfs_dir2_leafn_lasthash(args->dp, in xfs_da3_path_shift()
1985 struct xfs_da_args *args, in xfs_da_compname() argument
1989 return (args->namelen == len && memcmp(args->name, name, len) == 0) ? in xfs_da_compname()
2007 struct xfs_da_args *args, in xfs_da_grow_inode_int() argument
2011 struct xfs_trans *tp = args->trans; in xfs_da_grow_inode_int()
2012 struct xfs_inode *dp = args->dp; in xfs_da_grow_inode_int()
2013 int w = args->whichfork; in xfs_da_grow_inode_int()
2029 ASSERT(args->firstblock != NULL); in xfs_da_grow_inode_int()
2032 args->firstblock, args->total, &map, &nmap, in xfs_da_grow_inode_int()
2033 args->flist); in xfs_da_grow_inode_int()
2055 args->firstblock, args->total, in xfs_da_grow_inode_int()
2056 &mapp[mapi], &nmap, args->flist); in xfs_da_grow_inode_int()
2083 args->total -= dp->i_d.di_nblocks - nblks; in xfs_da_grow_inode_int()
2097 struct xfs_da_args *args, in xfs_da_grow_inode() argument
2103 trace_xfs_da_grow_inode(args); in xfs_da_grow_inode()
2105 bno = args->geo->leafblk; in xfs_da_grow_inode()
2106 error = xfs_da_grow_inode_int(args, &bno, args->geo->fsbcount); in xfs_da_grow_inode()
2122 struct xfs_da_args *args, in xfs_da3_swap_lastblock() argument
2152 trace_xfs_da_swap_lastblock(args); in xfs_da3_swap_lastblock()
2156 tp = args->trans; in xfs_da3_swap_lastblock()
2157 dp = args->dp; in xfs_da3_swap_lastblock()
2158 w = args->whichfork; in xfs_da3_swap_lastblock()
2161 lastoff = args->geo->freeblk; in xfs_da3_swap_lastblock()
2173 last_blkno = (xfs_dablk_t)lastoff - args->geo->fsbcount; in xfs_da3_swap_lastblock()
2180 memcpy(dead_buf->b_addr, last_buf->b_addr, args->geo->blksize); in xfs_da3_swap_lastblock()
2181 xfs_trans_log_buf(tp, dead_buf, 0, args->geo->blksize - 1); in xfs_da3_swap_lastblock()
2250 par_blkno = args->geo->leafblk; in xfs_da3_swap_lastblock()
2345 xfs_da_args_t *args, in xfs_da_shrink_inode() argument
2353 trace_xfs_da_shrink_inode(args); in xfs_da_shrink_inode()
2355 dp = args->dp; in xfs_da_shrink_inode()
2356 w = args->whichfork; in xfs_da_shrink_inode()
2357 tp = args->trans; in xfs_da_shrink_inode()
2358 count = args->geo->fsbcount; in xfs_da_shrink_inode()
2365 xfs_bmapi_aflag(w), 0, args->firstblock, in xfs_da_shrink_inode()
2366 args->flist, &done); in xfs_da_shrink_inode()
2370 error = xfs_da3_swap_lastblock(args, &dead_blkno, in xfs_da_shrink_inode()