Lines Matching refs:my_rsv

666 			struct ext2_reserve_window *my_rsv)  in ext2_try_to_allocate()  argument
676 if (my_rsv) { in ext2_try_to_allocate()
677 if (my_rsv->_rsv_start >= group_first_block) in ext2_try_to_allocate()
678 start = my_rsv->_rsv_start - group_first_block; in ext2_try_to_allocate()
679 if (my_rsv->_rsv_end < group_last_block) in ext2_try_to_allocate()
680 end = my_rsv->_rsv_end - group_first_block + 1; in ext2_try_to_allocate()
690 if (!my_rsv) { in ext2_try_to_allocate()
754 struct ext2_reserve_window_node *my_rsv, in find_next_reservable_window() argument
762 int size = my_rsv->rsv_goal_size; in find_next_reservable_window()
817 if ((prev != my_rsv) && (!rsv_is_empty(&my_rsv->rsv_window))) in find_next_reservable_window()
818 rsv_window_remove(sb, my_rsv); in find_next_reservable_window()
827 my_rsv->rsv_start = cur; in find_next_reservable_window()
828 my_rsv->rsv_end = cur + size - 1; in find_next_reservable_window()
829 my_rsv->rsv_alloc_hit = 0; in find_next_reservable_window()
831 if (prev != my_rsv) in find_next_reservable_window()
832 ext2_rsv_window_add(sb, my_rsv); in find_next_reservable_window()
874 static int alloc_new_reservation(struct ext2_reserve_window_node *my_rsv, in alloc_new_reservation() argument
894 size = my_rsv->rsv_goal_size; in alloc_new_reservation()
896 if (!rsv_is_empty(&my_rsv->rsv_window)) { in alloc_new_reservation()
911 if ((my_rsv->rsv_start <= group_end_block) && in alloc_new_reservation()
912 (my_rsv->rsv_end > group_end_block) && in alloc_new_reservation()
913 (start_block >= my_rsv->rsv_start)) in alloc_new_reservation()
916 if ((my_rsv->rsv_alloc_hit > in alloc_new_reservation()
917 (my_rsv->rsv_end - my_rsv->rsv_start + 1) / 2)) { in alloc_new_reservation()
927 my_rsv->rsv_goal_size= size; in alloc_new_reservation()
945 ret = find_next_reservable_window(search_head, my_rsv, sb, in alloc_new_reservation()
949 if (!rsv_is_empty(&my_rsv->rsv_window)) in alloc_new_reservation()
950 rsv_window_remove(sb, my_rsv); in alloc_new_reservation()
966 my_rsv->rsv_start - group_first_block, in alloc_new_reservation()
975 if (!rsv_is_empty(&my_rsv->rsv_window)) in alloc_new_reservation()
976 rsv_window_remove(sb, my_rsv); in alloc_new_reservation()
986 if (start_block >= my_rsv->rsv_start && start_block <= my_rsv->rsv_end) in alloc_new_reservation()
994 search_head = my_rsv; in alloc_new_reservation()
1016 static void try_to_extend_reservation(struct ext2_reserve_window_node *my_rsv, in try_to_extend_reservation() argument
1026 next = rb_next(&my_rsv->rsv_node); in try_to_extend_reservation()
1029 my_rsv->rsv_end += size; in try_to_extend_reservation()
1033 if ((next_rsv->rsv_start - my_rsv->rsv_end - 1) >= size) in try_to_extend_reservation()
1034 my_rsv->rsv_end += size; in try_to_extend_reservation()
1036 my_rsv->rsv_end = next_rsv->rsv_start - 1; in try_to_extend_reservation()
1070 struct ext2_reserve_window_node * my_rsv, in ext2_try_to_allocate_with_rsv() argument
1083 if (my_rsv == NULL) { in ext2_try_to_allocate_with_rsv()
1112 if (rsv_is_empty(&my_rsv->rsv_window) || (ret < 0) || in ext2_try_to_allocate_with_rsv()
1113 !goal_in_my_reservation(&my_rsv->rsv_window, in ext2_try_to_allocate_with_rsv()
1115 if (my_rsv->rsv_goal_size < *count) in ext2_try_to_allocate_with_rsv()
1116 my_rsv->rsv_goal_size = *count; in ext2_try_to_allocate_with_rsv()
1117 ret = alloc_new_reservation(my_rsv, grp_goal, sb, in ext2_try_to_allocate_with_rsv()
1122 if (!goal_in_my_reservation(&my_rsv->rsv_window, in ext2_try_to_allocate_with_rsv()
1126 int curr = my_rsv->rsv_end - in ext2_try_to_allocate_with_rsv()
1130 try_to_extend_reservation(my_rsv, sb, in ext2_try_to_allocate_with_rsv()
1134 if ((my_rsv->rsv_start > group_last_block) || in ext2_try_to_allocate_with_rsv()
1135 (my_rsv->rsv_end < group_first_block)) { in ext2_try_to_allocate_with_rsv()
1140 &num, &my_rsv->rsv_window); in ext2_try_to_allocate_with_rsv()
1142 my_rsv->rsv_alloc_hit += num; in ext2_try_to_allocate_with_rsv()
1223 struct ext2_reserve_window_node *my_rsv = NULL; in ext2_new_blocks() local
1257 my_rsv = &block_i->rsv_window_node; in ext2_new_blocks()
1284 if (my_rsv && (free_blocks < windowsz) in ext2_new_blocks()
1286 && (rsv_is_empty(&my_rsv->rsv_window))) in ext2_new_blocks()
1287 my_rsv = NULL; in ext2_new_blocks()
1304 my_rsv, &num); in ext2_new_blocks()
1336 if (my_rsv && (free_blocks <= (windowsz/2))) in ext2_new_blocks()
1347 bitmap_bh, -1, my_rsv, &num); in ext2_new_blocks()
1358 if (my_rsv) { in ext2_new_blocks()
1359 my_rsv = NULL; in ext2_new_blocks()