Lines Matching refs:bc_ops

137 	if (be32_to_cpu(block->bb_magic) != xfs_btree_magic(mp, cur->bc_ops))  in __xfs_btree_check_lblock_hdr()
142 cur->bc_ops->get_maxrecs(cur, level)) in __xfs_btree_check_lblock_hdr()
239 if (be32_to_cpu(block->bb_magic) != xfs_btree_magic(mp, cur->bc_ops)) in __xfs_btree_check_agblock()
244 cur->bc_ops->get_maxrecs(cur, level)) in __xfs_btree_check_agblock()
268 switch (cur->bc_ops->type) { in __xfs_btree_check_block()
283 if (cur->bc_ops->ptr_len == XFS_BTREE_SHORT_PTR_LEN) in xfs_btree_block_errtag()
322 switch (cur->bc_ops->type) { in __xfs_btree_check_ptr()
358 switch (cur->bc_ops->type) { in xfs_btree_check_ptr()
362 cur->bc_ops->name, cur->bc_flags, level, index, in xfs_btree_check_ptr()
369 cur->bc_ino.whichfork, cur->bc_ops->name, in xfs_btree_check_ptr()
375 cur->bc_ag.pag->pag_agno, cur->bc_ops->name, in xfs_btree_check_ptr()
485 error = cur->bc_ops->free_block(cur, bp); in xfs_btree_free_block()
523 ASSERT(!xfs_btree_is_bmap(cur->bc_ops) || cur->bc_bmap.allocated == 0 || in xfs_btree_del_cursor()
526 switch (cur->bc_ops->type) { in xfs_btree_del_cursor()
548 if (cur->bc_ops->type == XFS_BTREE_TYPE_MEM) in xfs_btree_buftarg()
558 if (cur->bc_ops->type == XFS_BTREE_TYPE_MEM) in xfs_btree_bbsize()
591 new = cur->bc_ops->dup_cursor(cur); in xfs_btree_dup_cursor()
610 cur->bc_ops->buf_ops); in xfs_btree_dup_cursor()
704 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) { in xfs_btree_block_len()
723 (n - 1) * cur->bc_ops->rec_len; in xfs_btree_rec_offset()
735 (n - 1) * cur->bc_ops->key_len; in xfs_btree_key_offset()
747 (n - 1) * cur->bc_ops->key_len + (cur->bc_ops->key_len / 2); in xfs_btree_high_key_offset()
760 cur->bc_ops->get_maxrecs(cur, level) * cur->bc_ops->key_len + in xfs_btree_ptr_offset()
761 (n - 1) * cur->bc_ops->ptr_len; in xfs_btree_ptr_offset()
824 ASSERT(cur->bc_ops->type == XFS_BTREE_TYPE_INODE); in xfs_btree_ifork_ptr()
974 mp->m_bsize, cur->bc_ops->buf_ops); in xfs_btree_readahead_fsblock()
980 mp->m_bsize, cur->bc_ops->buf_ops); in xfs_btree_readahead_fsblock()
1000 cur->bc_ops->buf_ops); in xfs_btree_readahead_memblock()
1006 cur->bc_ops->buf_ops); in xfs_btree_readahead_memblock()
1028 mp->m_bsize, cur->bc_ops->buf_ops); in xfs_btree_readahead_agblock()
1035 mp->m_bsize, cur->bc_ops->buf_ops); in xfs_btree_readahead_agblock()
1067 switch (cur->bc_ops->type) { in xfs_btree_readahead()
1092 switch (cur->bc_ops->type) { in xfs_btree_ptr_to_daddr()
1125 cur->bc_ops->buf_ops); in xfs_btree_readahead_ptr()
1146 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) { in xfs_btree_setbuf()
1164 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) in xfs_btree_ptr_is_null()
1175 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) in xfs_btree_set_ptr_null()
1187 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) in xfs_btree_ptrs_equal()
1204 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) { in xfs_btree_get_sibling()
1226 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) { in xfs_btree_set_sibling()
1310 switch (cur->bc_ops->type) { in xfs_btree_owner()
1330 xfs_btree_init_buf(cur->bc_mp, bp, cur->bc_ops, level, numrecs, in xfs_btree_init_block_cur()
1340 switch (cur->bc_ops->type) { in xfs_btree_buf_to_ptr()
1360 xfs_buf_set_ref(bp, cur->bc_ops->lru_refs); in xfs_btree_set_refs()
1381 (*bpp)->b_ops = cur->bc_ops->buf_ops; in xfs_btree_get_buf_block()
1410 cur->bc_ops->buf_ops); in xfs_btree_read_buf_block()
1432 memcpy(dst_key, src_key, numkeys * cur->bc_ops->key_len); in xfs_btree_copy_keys()
1446 memcpy(dst_rec, src_rec, numrecs * cur->bc_ops->rec_len); in xfs_btree_copy_recs()
1460 memcpy(dst_ptr, src_ptr, numptrs * cur->bc_ops->ptr_len); in xfs_btree_copy_ptrs()
1478 dst_key = (char *)key + (dir * cur->bc_ops->key_len); in xfs_btree_shift_keys()
1479 memmove(dst_key, key, numkeys * cur->bc_ops->key_len); in xfs_btree_shift_keys()
1497 dst_rec = (char *)rec + (dir * cur->bc_ops->rec_len); in xfs_btree_shift_recs()
1498 memmove(dst_rec, rec, numrecs * cur->bc_ops->rec_len); in xfs_btree_shift_recs()
1516 dst_ptr = (char *)ptr + (dir * cur->bc_ops->ptr_len); in xfs_btree_shift_ptrs()
1517 memmove(dst_ptr, ptr, numptrs * cur->bc_ops->ptr_len); in xfs_btree_shift_ptrs()
1643 (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) ? in xfs_btree_log_block()
1720 if (cur->bc_ops->type == XFS_BTREE_TYPE_INODE) in xfs_btree_increment()
1814 if (cur->bc_ops->type == XFS_BTREE_TYPE_INODE) in xfs_btree_decrement()
1866 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) { in xfs_btree_check_block_owner()
1950 cur->bc_ops->init_key_from_rec(kp, in xfs_lookup_get_search_key()
1966 if (cur->bc_ops->type == XFS_BTREE_TYPE_INODE) { in xfs_btree_init_ptr_from_cur()
1975 cur->bc_ops->init_ptr_from_cur(cur, ptr); in xfs_btree_init_ptr_from_cur()
2075 diff = cur->bc_ops->key_diff(cur, kp); in xfs_btree_lookup()
2153 ASSERT(cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING); in xfs_btree_high_key_from_key()
2155 (cur->bc_ops->key_len / 2)); in xfs_btree_high_key_from_key()
2172 cur->bc_ops->init_key_from_rec(key, rec); in xfs_btree_get_leaf_keys()
2174 if (cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING) { in xfs_btree_get_leaf_keys()
2176 cur->bc_ops->init_high_key_from_rec(&max_hkey, rec); in xfs_btree_get_leaf_keys()
2179 cur->bc_ops->init_high_key_from_rec(&hkey, rec); in xfs_btree_get_leaf_keys()
2185 memcpy(high, &max_hkey, cur->bc_ops->key_len / 2); in xfs_btree_get_leaf_keys()
2201 if (cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING) { in xfs_btree_get_node_keys()
2203 cur->bc_ops->key_len / 2); in xfs_btree_get_node_keys()
2213 memcpy(high, max_hkey, cur->bc_ops->key_len / 2); in xfs_btree_get_node_keys()
2216 cur->bc_ops->key_len); in xfs_btree_get_node_keys()
2245 return (cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING) || ptr == 1; in xfs_btree_needs_key_update()
2269 ASSERT(cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING); in __xfs_btree_updkeys()
2338 if (cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING) in xfs_btree_update_keys()
2467 if (lrecs == cur->bc_ops->get_maxrecs(cur, level)) in xfs_btree_lshift()
2508 ASSERT(cur->bc_ops->keys_inorder(cur, in xfs_btree_lshift()
2520 ASSERT(cur->bc_ops->recs_inorder(cur, in xfs_btree_lshift()
2563 if (cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING) { in xfs_btree_lshift()
2663 if (rrecs == cur->bc_ops->get_maxrecs(cur, level)) in xfs_btree_rshift()
2704 ASSERT(cur->bc_ops->keys_inorder(cur, rkp, in xfs_btree_rshift()
2749 if (cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING) { in xfs_btree_rshift()
2798 error = cur->bc_ops->alloc_block(cur, hint_block, new_block, stat); in xfs_btree_alloc_block()
2953 if (cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING) { in __xfs_btree_split()
3071 if (!xfs_btree_is_bmap(cur->bc_ops) || in xfs_btree_split()
3117 ASSERT(cur->bc_ops->type == XFS_BTREE_TYPE_INODE); in xfs_btree_new_iroot()
3145 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) in xfs_btree_new_iroot()
3209 cur->bc_ops->set_root(cur, ptr, inc); in xfs_btree_set_root()
3360 if (numrecs < cur->bc_ops->get_dmaxrecs(cur, level)) { in xfs_btree_make_block_unfull()
3442 if (cur->bc_ops->type != XFS_BTREE_TYPE_INODE && in xfs_btree_insrec()
3474 ASSERT(cur->bc_ops->recs_inorder(cur, rec, in xfs_btree_insrec()
3477 ASSERT(cur->bc_ops->keys_inorder(cur, key, in xfs_btree_insrec()
3488 if (numrecs == cur->bc_ops->get_maxrecs(cur, level)) { in xfs_btree_insrec()
3544 ASSERT(cur->bc_ops->keys_inorder(cur, kp, in xfs_btree_insrec()
3562 ASSERT(cur->bc_ops->recs_inorder(cur, rp, in xfs_btree_insrec()
3636 cur->bc_ops->init_rec_from_cur(cur, &rec); in xfs_btree_insert()
3637 cur->bc_ops->init_key_from_rec(key, &rec); in xfs_btree_insert()
3672 if (cur->bc_ops->update_cursor && in xfs_btree_insert()
3674 cur->bc_ops->update_cursor(pcur, cur); in xfs_btree_insert()
3722 ASSERT(cur->bc_ops->type == XFS_BTREE_TYPE_INODE); in xfs_btree_kill_iroot()
3748 if (numrecs > cur->bc_ops->get_dmaxrecs(cur, level)) in xfs_btree_kill_iroot()
3760 index = numrecs - cur->bc_ops->get_maxrecs(cur, level); in xfs_btree_kill_iroot()
4001 if (numrecs >= cur->bc_ops->get_minrecs(cur, level)) { in xfs_btree_delrec()
4016 if (cur->bc_ops->type == XFS_BTREE_TYPE_INODE) { in xfs_btree_delrec()
4093 cur->bc_ops->get_minrecs(tcur, level)) { in xfs_btree_delrec()
4099 cur->bc_ops->get_minrecs(tcur, level)); in xfs_btree_delrec()
4178 cur->bc_ops->get_minrecs(tcur, level)) { in xfs_btree_delrec()
4184 cur->bc_ops->get_minrecs(tcur, level)); in xfs_btree_delrec()
4211 cur->bc_ops->get_maxrecs(cur, level)) { in xfs_btree_delrec()
4228 cur->bc_ops->get_maxrecs(cur, level)) { in xfs_btree_delrec()
4333 else if (cur->bc_ops->type == XFS_BTREE_TYPE_INODE || in xfs_btree_delrec()
4402 if (joined && (cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING)) { in xfs_btree_delete()
4600 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) { in xfs_btree_block_change_owner()
4618 ASSERT(cur->bc_ops->type == XFS_BTREE_TYPE_INODE); in xfs_btree_block_change_owner()
4882 ASSERT(cur->bc_ops->init_high_key_from_rec); in xfs_btree_simple_query_range()
4883 ASSERT(cur->bc_ops->diff_two_keys); in xfs_btree_simple_query_range()
4909 cur->bc_ops->init_high_key_from_rec(&rec_key, recp); in xfs_btree_simple_query_range()
4916 cur->bc_ops->init_key_from_rec(&rec_key, recp); in xfs_btree_simple_query_range()
5009 cur->bc_ops->init_high_key_from_rec(&rec_hkey, recp); in xfs_btree_overlapped_query_range()
5010 cur->bc_ops->init_key_from_rec(&rec_key, recp); in xfs_btree_overlapped_query_range()
5100 cur->bc_ops->init_rec_from_cur(cur, &rec); in xfs_btree_key_from_irec()
5101 cur->bc_ops->init_key_from_rec(key, &rec); in xfs_btree_key_from_irec()
5129 if (!(cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING)) in xfs_btree_query_range()
5183 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) in xfs_btree_diff_two_ptrs()
5213 cur->bc_ops->init_key_from_rec(&rec_key, rec); in xfs_btree_has_records_helper()
5234 key_contig = cur->bc_ops->keys_contiguous(cur, &info->high_key, in xfs_btree_has_records_helper()
5237 !(cur->bc_ops->geom_flags & XFS_BTGEO_OVERLAPPING)) in xfs_btree_has_records_helper()
5247 cur->bc_ops->init_high_key_from_rec(&rec_high_key, rec); in xfs_btree_has_records_helper()
5284 if (!cur->bc_ops->keys_contiguous) { in xfs_btree_has_records()
5331 if (cur->bc_ops->ptr_len == XFS_BTREE_LONG_PTR_LEN) in xfs_btree_has_more_records()