Lines Matching full:el
586 node->el = NULL; in ocfs2_reinit_path()
629 dest->p_node[i].el = src->p_node[i].el; in ocfs2_cp_path()
651 dest->p_node[i].el = src->p_node[i].el; in ocfs2_mv_path()
654 src->p_node[i].el = NULL; in ocfs2_mv_path()
677 path->p_node[index].el = &eb->h_list; in ocfs2_path_insert_eb()
766 int ocfs2_search_extent_list(struct ocfs2_extent_list *el, u32 v_cluster) in ocfs2_search_extent_list() argument
773 for(i = 0; i < le16_to_cpu(el->l_next_free_rec); i++) { in ocfs2_search_extent_list()
774 rec = &el->l_recs[i]; in ocfs2_search_extent_list()
777 clusters = ocfs2_rec_clusters(el, rec); in ocfs2_search_extent_list()
951 struct ocfs2_extent_list *el = NULL; in ocfs2_num_free_extents() local
956 el = et->et_root_el; in ocfs2_num_free_extents()
967 el = &eb->h_list; in ocfs2_num_free_extents()
970 if (el->l_tree_depth != 0) { in ocfs2_num_free_extents()
975 le16_to_cpu(el->l_tree_depth)); in ocfs2_num_free_extents()
979 retval = le16_to_cpu(el->l_count) - le16_to_cpu(el->l_next_free_rec); in ocfs2_num_free_extents()
1084 static inline u32 ocfs2_sum_rightmost_rec(struct ocfs2_extent_list *el) in ocfs2_sum_rightmost_rec() argument
1088 i = le16_to_cpu(el->l_next_free_rec) - 1; in ocfs2_sum_rightmost_rec()
1090 return le32_to_cpu(el->l_recs[i].e_cpos) + in ocfs2_sum_rightmost_rec()
1091 ocfs2_rec_clusters(el, &el->l_recs[i]); in ocfs2_sum_rightmost_rec()
1103 struct ocfs2_extent_list *el; in ocfs2_adjust_rightmost_branch() local
1130 el = path_leaf_el(path); in ocfs2_adjust_rightmost_branch()
1131 rec = &el->l_recs[le16_to_cpu(el->l_next_free_rec) - 1]; in ocfs2_adjust_rightmost_branch()
1163 struct ocfs2_extent_list *el; in ocfs2_add_branch() local
1170 el = &eb->h_list; in ocfs2_add_branch()
1172 el = et->et_root_el; in ocfs2_add_branch()
1175 BUG_ON(!el->l_tree_depth); in ocfs2_add_branch()
1177 new_blocks = le16_to_cpu(el->l_tree_depth); in ocfs2_add_branch()
1310 /* Link the new branch into the rest of the tree (el will in ocfs2_add_branch()
1312 i = le16_to_cpu(el->l_next_free_rec); in ocfs2_add_branch()
1313 el->l_recs[i].e_blkno = cpu_to_le64(next_blkno); in ocfs2_add_branch()
1314 el->l_recs[i].e_cpos = cpu_to_le32(new_cpos); in ocfs2_add_branch()
1315 el->l_recs[i].e_int_clusters = 0; in ocfs2_add_branch()
1316 le16_add_cpu(&el->l_next_free_rec, 1); in ocfs2_add_branch()
1462 struct ocfs2_extent_list *el; in ocfs2_find_branch_target() local
1468 el = et->et_root_el; in ocfs2_find_branch_target()
1470 while(le16_to_cpu(el->l_tree_depth) > 1) { in ocfs2_find_branch_target()
1471 if (le16_to_cpu(el->l_next_free_rec) == 0) { in ocfs2_find_branch_target()
1477 i = le16_to_cpu(el->l_next_free_rec) - 1; in ocfs2_find_branch_target()
1478 blkno = le64_to_cpu(el->l_recs[i].e_blkno); in ocfs2_find_branch_target()
1496 el = &eb->h_list; in ocfs2_find_branch_target()
1498 if (le16_to_cpu(el->l_next_free_rec) < in ocfs2_find_branch_target()
1499 le16_to_cpu(el->l_count)) { in ocfs2_find_branch_target()
1508 el = et->et_root_el; in ocfs2_find_branch_target()
1509 if (!lowest_bh && (el->l_next_free_rec == el->l_count)) in ocfs2_find_branch_target()
1534 struct ocfs2_extent_list *el = et->et_root_el; in ocfs2_grow_tree() local
1535 int depth = le16_to_cpu(el->l_tree_depth); in ocfs2_grow_tree()
1600 static void ocfs2_shift_records_right(struct ocfs2_extent_list *el) in ocfs2_shift_records_right() argument
1602 int next_free = le16_to_cpu(el->l_next_free_rec); in ocfs2_shift_records_right()
1603 int count = le16_to_cpu(el->l_count); in ocfs2_shift_records_right()
1612 memmove(&el->l_recs[1], &el->l_recs[0], num_bytes); in ocfs2_shift_records_right()
1615 static void ocfs2_rotate_leaf(struct ocfs2_extent_list *el, in ocfs2_rotate_leaf() argument
1622 next_free = le16_to_cpu(el->l_next_free_rec); in ocfs2_rotate_leaf()
1623 has_empty = ocfs2_is_empty_extent(&el->l_recs[0]); in ocfs2_rotate_leaf()
1628 BUG_ON(el->l_next_free_rec == el->l_count && !has_empty); in ocfs2_rotate_leaf()
1641 el->l_recs[i] = el->l_recs[i+1]; in ocfs2_rotate_leaf()
1650 rec = &el->l_recs[i]; in ocfs2_rotate_leaf()
1659 le16_to_cpu(el->l_count)); in ocfs2_rotate_leaf()
1662 BUG_ON(insert_index >= le16_to_cpu(el->l_count)); in ocfs2_rotate_leaf()
1669 BUG_ON(next_free >= le16_to_cpu(el->l_count)); in ocfs2_rotate_leaf()
1673 memmove(&el->l_recs[insert_index + 1], in ocfs2_rotate_leaf()
1674 &el->l_recs[insert_index], in ocfs2_rotate_leaf()
1684 el->l_next_free_rec = cpu_to_le16(next_free); in ocfs2_rotate_leaf()
1688 BUG_ON(le16_to_cpu(el->l_next_free_rec) > le16_to_cpu(el->l_count)); in ocfs2_rotate_leaf()
1690 el->l_recs[insert_index] = *insert_rec; in ocfs2_rotate_leaf()
1694 static void ocfs2_remove_empty_extent(struct ocfs2_extent_list *el) in ocfs2_remove_empty_extent() argument
1696 int size, num_recs = le16_to_cpu(el->l_next_free_rec); in ocfs2_remove_empty_extent()
1700 if (ocfs2_is_empty_extent(&el->l_recs[0])) { in ocfs2_remove_empty_extent()
1703 memmove(&el->l_recs[0], &el->l_recs[1], size); in ocfs2_remove_empty_extent()
1704 memset(&el->l_recs[num_recs], 0, in ocfs2_remove_empty_extent()
1706 el->l_next_free_rec = cpu_to_le16(num_recs); in ocfs2_remove_empty_extent()
1717 static void ocfs2_create_empty_extent(struct ocfs2_extent_list *el) in ocfs2_create_empty_extent() argument
1719 int next_free = le16_to_cpu(el->l_next_free_rec); in ocfs2_create_empty_extent()
1721 BUG_ON(le16_to_cpu(el->l_tree_depth) != 0); in ocfs2_create_empty_extent()
1726 if (ocfs2_is_empty_extent(&el->l_recs[0])) in ocfs2_create_empty_extent()
1729 mlog_bug_on_msg(el->l_count == el->l_next_free_rec, in ocfs2_create_empty_extent()
1732 le16_to_cpu(el->l_count), in ocfs2_create_empty_extent()
1733 le16_to_cpu(el->l_tree_depth)); in ocfs2_create_empty_extent()
1735 ocfs2_shift_records_right(el); in ocfs2_create_empty_extent()
1738 le16_add_cpu(&el->l_next_free_rec, 1); in ocfs2_create_empty_extent()
1739 memset(&el->l_recs[0], 0, sizeof(struct ocfs2_extent_rec)); in ocfs2_create_empty_extent()
1801 struct ocfs2_extent_list *el; in __ocfs2_find_path() local
1804 el = root_el; in __ocfs2_find_path()
1805 while (el->l_tree_depth) { in __ocfs2_find_path()
1806 if (unlikely(le16_to_cpu(el->l_tree_depth) >= OCFS2_MAX_PATH_DEPTH)) { in __ocfs2_find_path()
1810 le16_to_cpu(el->l_tree_depth)); in __ocfs2_find_path()
1814 if (le16_to_cpu(el->l_next_free_rec) == 0) { in __ocfs2_find_path()
1818 le16_to_cpu(el->l_tree_depth)); in __ocfs2_find_path()
1824 for(i = 0; i < le16_to_cpu(el->l_next_free_rec) - 1; i++) { in __ocfs2_find_path()
1825 rec = &el->l_recs[i]; in __ocfs2_find_path()
1833 ocfs2_rec_clusters(el, rec); in __ocfs2_find_path()
1838 blkno = le64_to_cpu(el->l_recs[i].e_blkno); in __ocfs2_find_path()
1843 le16_to_cpu(el->l_tree_depth), i); in __ocfs2_find_path()
1857 el = &eb->h_list; in __ocfs2_find_path()
1859 if (le16_to_cpu(el->l_next_free_rec) > in __ocfs2_find_path()
1860 le16_to_cpu(el->l_count)) { in __ocfs2_find_path()
1865 le16_to_cpu(el->l_next_free_rec), in __ocfs2_find_path()
1866 le16_to_cpu(el->l_count)); in __ocfs2_find_path()
1921 struct ocfs2_extent_list *el = &eb->h_list; in find_leaf_ins() local
1925 if (le16_to_cpu(el->l_tree_depth) == 0) { in find_leaf_ins()
2056 struct ocfs2_extent_list *el, *left_el, *right_el; in ocfs2_complete_edge_insert() local
2083 el = left_path->p_node[i].el; in ocfs2_complete_edge_insert()
2085 left_rec = &el->l_recs[idx]; in ocfs2_complete_edge_insert()
2087 el = right_path->p_node[i].el; in ocfs2_complete_edge_insert()
2088 right_rec = &el->l_recs[0]; in ocfs2_complete_edge_insert()
2099 left_el = left_path->p_node[i].el; in ocfs2_complete_edge_insert()
2100 right_el = right_path->p_node[i].el; in ocfs2_complete_edge_insert()
2108 el = left_path->p_node[subtree_index].el; in ocfs2_complete_edge_insert()
2109 left_el = left_path->p_node[subtree_index + 1].el; in ocfs2_complete_edge_insert()
2110 right_el = right_path->p_node[subtree_index + 1].el; in ocfs2_complete_edge_insert()
2112 ocfs2_adjust_root_records(el, left_el, right_el, in ocfs2_complete_edge_insert()
2228 struct ocfs2_extent_list *el; in ocfs2_find_cpos_for_left_leaf() local
2239 el = path->p_node[i].el; in ocfs2_find_cpos_for_left_leaf()
2245 for(j = 0; j < le16_to_cpu(el->l_next_free_rec); j++) { in ocfs2_find_cpos_for_left_leaf()
2246 if (le64_to_cpu(el->l_recs[j].e_blkno) == blkno) { in ocfs2_find_cpos_for_left_leaf()
2265 *cpos = le32_to_cpu(el->l_recs[j - 1].e_cpos); in ocfs2_find_cpos_for_left_leaf()
2266 *cpos = *cpos + ocfs2_rec_clusters(el, in ocfs2_find_cpos_for_left_leaf()
2267 &el->l_recs[j - 1]); in ocfs2_find_cpos_for_left_leaf()
2336 static int ocfs2_leftmost_rec_contains(struct ocfs2_extent_list *el, u32 cpos) in ocfs2_leftmost_rec_contains() argument
2338 int next_free = le16_to_cpu(el->l_next_free_rec); in ocfs2_leftmost_rec_contains()
2345 rec = &el->l_recs[0]; in ocfs2_leftmost_rec_contains()
2350 rec = &el->l_recs[1]; in ocfs2_leftmost_rec_contains()
2353 range = le32_to_cpu(rec->e_cpos) + ocfs2_rec_clusters(el, rec); in ocfs2_leftmost_rec_contains()
2542 struct ocfs2_extent_list *el; in ocfs2_update_edge_lengths() local
2556 el = &eb->h_list; in ocfs2_update_edge_lengths()
2557 BUG_ON(le16_to_cpu(el->l_next_free_rec) == 0); in ocfs2_update_edge_lengths()
2558 idx = le16_to_cpu(el->l_next_free_rec) - 1; in ocfs2_update_edge_lengths()
2559 rec = &el->l_recs[idx]; in ocfs2_update_edge_lengths()
2560 range = le32_to_cpu(rec->e_cpos) + ocfs2_rec_clusters(el, rec); in ocfs2_update_edge_lengths()
2563 el = path->p_node[i].el; in ocfs2_update_edge_lengths()
2564 idx = le16_to_cpu(el->l_next_free_rec) - 1; in ocfs2_update_edge_lengths()
2565 rec = &el->l_recs[idx]; in ocfs2_update_edge_lengths()
2583 struct ocfs2_extent_list *el; in ocfs2_unlink_path() local
2594 el = &eb->h_list; in ocfs2_unlink_path()
2595 if (le16_to_cpu(el->l_next_free_rec) > 1) { in ocfs2_unlink_path()
2601 le16_to_cpu(el->l_next_free_rec)); in ocfs2_unlink_path()
2608 el->l_next_free_rec = 0; in ocfs2_unlink_path()
2609 memset(&el->l_recs[0], 0, sizeof(struct ocfs2_extent_rec)); in ocfs2_unlink_path()
2630 struct ocfs2_extent_list *root_el = left_path->p_node[subtree_index].el; in ocfs2_unlink_subtree()
2823 struct ocfs2_extent_list *el; in ocfs2_find_cpos_for_right_leaf() local
2837 el = path->p_node[i].el; in ocfs2_find_cpos_for_right_leaf()
2843 next_free = le16_to_cpu(el->l_next_free_rec); in ocfs2_find_cpos_for_right_leaf()
2844 for(j = 0; j < le16_to_cpu(el->l_next_free_rec); j++) { in ocfs2_find_cpos_for_right_leaf()
2845 if (le64_to_cpu(el->l_recs[j].e_blkno) == blkno) { in ocfs2_find_cpos_for_right_leaf()
2864 *cpos = le32_to_cpu(el->l_recs[j + 1].e_cpos); in ocfs2_find_cpos_for_right_leaf()
2893 struct ocfs2_extent_list *el = path_leaf_el(path); in ocfs2_rotate_rightmost_leaf_left() local
2895 if (!ocfs2_is_empty_extent(&el->l_recs[0])) in ocfs2_rotate_rightmost_leaf_left()
2905 ocfs2_remove_empty_extent(el); in ocfs2_rotate_rightmost_leaf_left()
3038 struct ocfs2_extent_list *el; in ocfs2_remove_rightmost_path() local
3103 el = et->et_root_el; in ocfs2_remove_rightmost_path()
3104 el->l_tree_depth = 0; in ocfs2_remove_rightmost_path()
3105 el->l_next_free_rec = 0; in ocfs2_remove_rightmost_path()
3106 memset(&el->l_recs[0], 0, sizeof(struct ocfs2_extent_rec)); in ocfs2_remove_rightmost_path()
3166 struct ocfs2_extent_list *el; in ocfs2_rotate_tree_left() local
3168 el = path_leaf_el(path); in ocfs2_rotate_tree_left()
3169 if (!ocfs2_is_empty_extent(&el->l_recs[0])) in ocfs2_rotate_tree_left()
3198 el = &eb->h_list; in ocfs2_rotate_tree_left()
3205 if (le16_to_cpu(el->l_next_free_rec) > 1) in ocfs2_rotate_tree_left()
3208 if (le16_to_cpu(el->l_next_free_rec) == 0) { in ocfs2_rotate_tree_left()
3269 static void ocfs2_cleanup_merge(struct ocfs2_extent_list *el, in ocfs2_cleanup_merge() argument
3272 struct ocfs2_extent_rec *rec = &el->l_recs[index]; in ocfs2_cleanup_merge()
3287 BUG_ON(ocfs2_is_empty_extent(&el->l_recs[0])); in ocfs2_cleanup_merge()
3289 memmove(&el->l_recs[1], &el->l_recs[0], size); in ocfs2_cleanup_merge()
3297 memset(&el->l_recs[0], 0, sizeof(struct ocfs2_extent_rec)); in ocfs2_cleanup_merge()
3368 struct ocfs2_extent_list *el = path_leaf_el(left_path); in ocfs2_merge_rec_right() local
3372 BUG_ON(index >= le16_to_cpu(el->l_next_free_rec)); in ocfs2_merge_rec_right()
3373 left_rec = &el->l_recs[index]; in ocfs2_merge_rec_right()
3375 if (index == le16_to_cpu(el->l_next_free_rec) - 1 && in ocfs2_merge_rec_right()
3376 le16_to_cpu(el->l_next_free_rec) == le16_to_cpu(el->l_count)) { in ocfs2_merge_rec_right()
3436 BUG_ON(index == le16_to_cpu(el->l_next_free_rec) - 1); in ocfs2_merge_rec_right()
3437 right_rec = &el->l_recs[index + 1]; in ocfs2_merge_rec_right()
3455 ocfs2_cleanup_merge(el, index); in ocfs2_merge_rec_right()
3532 struct ocfs2_extent_list *el = path_leaf_el(right_path); in ocfs2_merge_rec_left() local
3540 right_rec = &el->l_recs[index]; in ocfs2_merge_rec_left()
3597 left_rec = &el->l_recs[index - 1]; in ocfs2_merge_rec_left()
3598 if (ocfs2_is_empty_extent(&el->l_recs[0])) in ocfs2_merge_rec_left()
3623 ocfs2_cleanup_merge(el, index); in ocfs2_merge_rec_left()
3635 le16_to_cpu(el->l_next_free_rec) == 1) { in ocfs2_merge_rec_left()
3676 struct ocfs2_extent_list *el = path_leaf_el(path); in ocfs2_try_to_merge_extent() local
3677 struct ocfs2_extent_rec *rec = &el->l_recs[split_index]; in ocfs2_try_to_merge_extent()
3703 rec = &el->l_recs[split_index]; in ocfs2_try_to_merge_extent()
3736 BUG_ON(!ocfs2_is_empty_extent(&el->l_recs[0])); in ocfs2_try_to_merge_extent()
3754 rec = &el->l_recs[split_index]; in ocfs2_try_to_merge_extent()
3875 struct ocfs2_extent_list *el, in ocfs2_insert_at_leaf() argument
3882 BUG_ON(le16_to_cpu(el->l_tree_depth) != 0); in ocfs2_insert_at_leaf()
3885 i = ocfs2_search_extent_list(el, le32_to_cpu(insert_rec->e_cpos)); in ocfs2_insert_at_leaf()
3887 rec = &el->l_recs[i]; in ocfs2_insert_at_leaf()
3898 rec = &el->l_recs[i]; in ocfs2_insert_at_leaf()
3911 if (le16_to_cpu(el->l_next_free_rec) == 0 || in ocfs2_insert_at_leaf()
3912 ((le16_to_cpu(el->l_next_free_rec) == 1) && in ocfs2_insert_at_leaf()
3913 ocfs2_is_empty_extent(&el->l_recs[0]))) { in ocfs2_insert_at_leaf()
3914 el->l_recs[0] = *insert_rec; in ocfs2_insert_at_leaf()
3915 el->l_next_free_rec = cpu_to_le16(1); in ocfs2_insert_at_leaf()
3923 i = le16_to_cpu(el->l_next_free_rec) - 1; in ocfs2_insert_at_leaf()
3924 rec = &el->l_recs[i]; in ocfs2_insert_at_leaf()
3929 mlog_bug_on_msg(le16_to_cpu(el->l_next_free_rec) >= in ocfs2_insert_at_leaf()
3930 le16_to_cpu(el->l_count), in ocfs2_insert_at_leaf()
3935 le16_to_cpu(el->l_tree_depth), in ocfs2_insert_at_leaf()
3936 le16_to_cpu(el->l_count), in ocfs2_insert_at_leaf()
3937 le16_to_cpu(el->l_next_free_rec), in ocfs2_insert_at_leaf()
3938 le32_to_cpu(el->l_recs[i].e_cpos), in ocfs2_insert_at_leaf()
3939 le16_to_cpu(el->l_recs[i].e_leaf_clusters), in ocfs2_insert_at_leaf()
3943 el->l_recs[i] = *insert_rec; in ocfs2_insert_at_leaf()
3944 le16_add_cpu(&el->l_next_free_rec, 1); in ocfs2_insert_at_leaf()
3959 ocfs2_rotate_leaf(el, insert_rec); in ocfs2_insert_at_leaf()
3969 struct ocfs2_extent_list *el; in ocfs2_adjust_rightmost_records() local
3977 el = path->p_node[i].el; in ocfs2_adjust_rightmost_records()
3979 next_free = le16_to_cpu(el->l_next_free_rec); in ocfs2_adjust_rightmost_records()
3987 rec = &el->l_recs[next_free - 1]; in ocfs2_adjust_rightmost_records()
4006 struct ocfs2_extent_list *el; in ocfs2_append_rec_to_path() local
4022 el = path_leaf_el(right_path); in ocfs2_append_rec_to_path()
4023 next_free = le16_to_cpu(el->l_next_free_rec); in ocfs2_append_rec_to_path()
4025 (next_free == 1 && ocfs2_is_empty_extent(&el->l_recs[0]))) { in ocfs2_append_rec_to_path()
4092 struct ocfs2_extent_list *left_el = NULL, *right_el, *insert_el, *el; in ocfs2_split_record() local
4099 el = right_el; in ocfs2_split_record()
4101 index = ocfs2_search_extent_list(el, cpos); in ocfs2_split_record()
4104 BUG_ON(ocfs2_is_empty_extent(&el->l_recs[0])); in ocfs2_split_record()
4136 el = left_el; in ocfs2_split_record()
4150 el = left_el; in ocfs2_split_record()
4152 index = ocfs2_search_extent_list(el, cpos); in ocfs2_split_record()
4156 rec = &el->l_recs[index]; in ocfs2_split_record()
4260 struct ocfs2_extent_list *el; in ocfs2_do_insert_extent() local
4262 el = et->et_root_el; in ocfs2_do_insert_extent()
4271 if (le16_to_cpu(el->l_tree_depth) == 0) { in ocfs2_do_insert_extent()
4272 ocfs2_insert_at_leaf(et, insert_rec, el, type); in ocfs2_do_insert_extent()
4365 struct ocfs2_extent_list *el, int index, in ocfs2_figure_merge_contig_type() argument
4380 rec = &el->l_recs[index - 1]; in ocfs2_figure_merge_contig_type()
4423 if (split_rec->e_cpos == el->l_recs[index].e_cpos) in ocfs2_figure_merge_contig_type()
4431 if (index < (le16_to_cpu(el->l_next_free_rec) - 1)) in ocfs2_figure_merge_contig_type()
4432 rec = &el->l_recs[index + 1]; in ocfs2_figure_merge_contig_type()
4433 else if (le16_to_cpu(el->l_next_free_rec) == le16_to_cpu(el->l_count) && in ocfs2_figure_merge_contig_type()
4493 struct ocfs2_extent_list *el, in ocfs2_figure_contig_type() argument
4499 BUG_ON(le16_to_cpu(el->l_tree_depth) != 0); in ocfs2_figure_contig_type()
4501 for(i = 0; i < le16_to_cpu(el->l_next_free_rec); i++) { in ocfs2_figure_contig_type()
4502 contig_type = ocfs2_et_extent_contig(et, &el->l_recs[i], in ocfs2_figure_contig_type()
4513 &el->l_recs[insert->ins_contig_index]; in ocfs2_figure_contig_type()
4538 struct ocfs2_extent_list *el, in ocfs2_figure_appending_type() argument
4547 BUG_ON(le16_to_cpu(el->l_tree_depth) != 0); in ocfs2_figure_appending_type()
4549 if (!el->l_next_free_rec) in ocfs2_figure_appending_type()
4552 if (ocfs2_is_empty_extent(&el->l_recs[0])) { in ocfs2_figure_appending_type()
4554 if (le16_to_cpu(el->l_next_free_rec) == 1) in ocfs2_figure_appending_type()
4558 i = le16_to_cpu(el->l_next_free_rec) - 1; in ocfs2_figure_appending_type()
4559 rec = &el->l_recs[i]; in ocfs2_figure_appending_type()
4592 struct ocfs2_extent_list *el; in ocfs2_figure_insert_type() local
4598 el = et->et_root_el; in ocfs2_figure_insert_type()
4599 insert->ins_tree_depth = le16_to_cpu(el->l_tree_depth); in ocfs2_figure_insert_type()
4601 if (el->l_tree_depth) { in ocfs2_figure_insert_type()
4616 el = &eb->h_list; in ocfs2_figure_insert_type()
4627 *free_records = le16_to_cpu(el->l_count) - in ocfs2_figure_insert_type()
4628 le16_to_cpu(el->l_next_free_rec); in ocfs2_figure_insert_type()
4631 ocfs2_figure_contig_type(et, insert, el, insert_rec); in ocfs2_figure_insert_type()
4632 ocfs2_figure_appending_type(insert, el, insert_rec); in ocfs2_figure_insert_type()
4655 el = path_leaf_el(path); in ocfs2_figure_insert_type()
4665 ocfs2_figure_contig_type(et, insert, el, insert_rec); in ocfs2_figure_insert_type()
4696 ocfs2_figure_appending_type(insert, el, insert_rec); in ocfs2_figure_insert_type()
4997 struct ocfs2_extent_list *el; in ocfs2_split_and_insert() local
5011 el = path_leaf_el(path); in ocfs2_split_and_insert()
5012 split_index = ocfs2_search_extent_list(el, cpos); in ocfs2_split_and_insert()
5031 struct ocfs2_extent_list *el, in ocfs2_replace_extent_rec() argument
5044 el->l_recs[split_index] = *split_rec; in ocfs2_replace_extent_rec()
5079 struct ocfs2_extent_list *el = path_leaf_el(path); in ocfs2_split_extent() local
5081 struct ocfs2_extent_rec *rec = &el->l_recs[split_index]; in ocfs2_split_extent()
5092 ret = ocfs2_figure_merge_contig_type(et, path, el, in ocfs2_split_extent()
5122 ctxt.c_has_empty_extent = ocfs2_is_empty_extent(&el->l_recs[0]); in ocfs2_split_extent()
5130 ret = ocfs2_replace_extent_rec(handle, et, path, el, in ocfs2_split_extent()
5175 struct ocfs2_extent_list *el; in ocfs2_change_extent_flag() local
5190 el = path_leaf_el(left_path); in ocfs2_change_extent_flag()
5192 index = ocfs2_search_extent_list(el, cpos); in ocfs2_change_extent_flag()
5203 rec = &el->l_recs[index]; in ocfs2_change_extent_flag()
5294 struct ocfs2_extent_list *rightmost_el, *el; in ocfs2_split_tree() local
5302 el = path_leaf_el(path); in ocfs2_split_tree()
5303 rec = &el->l_recs[index]; in ocfs2_split_tree()
5366 struct ocfs2_extent_list *el = path_leaf_el(path); in ocfs2_truncate_rec() local
5370 if (ocfs2_is_empty_extent(&el->l_recs[0]) && index > 0) { in ocfs2_truncate_rec()
5389 if (index == (le16_to_cpu(el->l_next_free_rec) - 1) && in ocfs2_truncate_rec()
5402 rec = &el->l_recs[index]; in ocfs2_truncate_rec()
5424 if (left_cpos && le16_to_cpu(el->l_next_free_rec) > 1) { in ocfs2_truncate_rec()
5461 rec_range = le32_to_cpu(rec->e_cpos) + ocfs2_rec_clusters(el, rec); in ocfs2_truncate_rec()
5468 ocfs2_cleanup_merge(el, index); in ocfs2_truncate_rec()
5470 next_free = le16_to_cpu(el->l_next_free_rec); in ocfs2_truncate_rec()
5476 rec = &el->l_recs[next_free - 1]; in ocfs2_truncate_rec()
5528 struct ocfs2_extent_list *el; in ocfs2_remove_extent() local
5550 el = path_leaf_el(path); in ocfs2_remove_extent()
5551 index = ocfs2_search_extent_list(el, cpos); in ocfs2_remove_extent()
5577 rec = &el->l_recs[index]; in ocfs2_remove_extent()
5578 rec_range = le32_to_cpu(rec->e_cpos) + ocfs2_rec_clusters(el, rec); in ocfs2_remove_extent()
5586 ocfs2_rec_clusters(el, rec)); in ocfs2_remove_extent()
5615 el = path_leaf_el(path); in ocfs2_remove_extent()
5616 index = ocfs2_search_extent_list(el, cpos); in ocfs2_remove_extent()
5630 rec = &el->l_recs[index]; in ocfs2_remove_extent()
5632 ocfs2_rec_clusters(el, rec); in ocfs2_remove_extent()
5638 ocfs2_rec_clusters(el, rec)); in ocfs2_remove_extent()
7237 struct ocfs2_extent_list *el; in ocfs2_commit_truncate() local
7288 * By now, el will point to the extent list on the bottom most in ocfs2_commit_truncate()
7298 el = path_leaf_el(path); in ocfs2_commit_truncate()
7299 if (le16_to_cpu(el->l_next_free_rec) == 0) { in ocfs2_commit_truncate()
7308 i = le16_to_cpu(el->l_next_free_rec) - 1; in ocfs2_commit_truncate()
7309 rec = &el->l_recs[i]; in ocfs2_commit_truncate()
7311 range = le32_to_cpu(rec->e_cpos) + ocfs2_rec_clusters(el, rec); in ocfs2_commit_truncate()
7341 trunc_len = ocfs2_rec_clusters(el, rec); in ocfs2_commit_truncate()