Lines Matching full:merge
212 /* Don't merge compressed extents, we need to know their actual size. */ in can_merge_extent_map()
220 * We don't want to merge stuff that hasn't been written to the log yet in can_merge_extent_map()
230 /* Check to see if two extent_map structs are adjacent and safe to merge. */
252 * Handle the on-disk data extents merge for @prev and @next.
254 * @prev: left extent to merge
255 * @next: right extent to merge
256 * @merged: the extent we will not discard after the merge; updated with new values
293 * For case 2), we just merge the two data extents into one. in merge_ondisk_extents()
345 struct extent_map *merge = NULL; in try_merge_map() local
365 merge = rb_entry(rb, struct extent_map, rb_node); in try_merge_map()
366 if (rb && can_merge_extent_map(merge) && mergeable_maps(merge, em)) { in try_merge_map()
367 em->start = merge->start; in try_merge_map()
368 em->len += merge->len; in try_merge_map()
369 em->generation = max(em->generation, merge->generation); in try_merge_map()
372 merge_ondisk_extents(merge, em, em); in try_merge_map()
376 remove_em(inode, merge); in try_merge_map()
377 free_extent_map(merge); in try_merge_map()
383 merge = rb_entry(rb, struct extent_map, rb_node); in try_merge_map()
384 if (rb && can_merge_extent_map(merge) && mergeable_maps(em, merge)) { in try_merge_map()
385 em->len += merge->len; in try_merge_map()
387 merge_ondisk_extents(em, merge, em); in try_merge_map()
389 em->generation = max(em->generation, merge->generation); in try_merge_map()
391 remove_em(inode, merge); in try_merge_map()
392 free_extent_map(merge); in try_merge_map()
484 * forward/backward merge with existing mappings. The extent_map struct passed
486 * taken, or a reference dropped if the merge attempt was successful.
692 * b) Merge the existing extent with @em_in passed in.
745 "extent map merge error existing [%llu, %llu) with em [%llu, %llu) start %llu", in btrfs_add_extent_mapping()