Lines Matching full:k
27 return inode->bi_dir == d.k->p.inode && in inode_points_to_dirent()
28 inode->bi_dir_offset == d.k->p.offset; in inode_points_to_dirent()
79 0, k, ({ in bch2_count_inode_sectors()
80 if (bkey_extent_is_allocation(k.k)) in bch2_count_inode_sectors()
81 sectors += k.k->size; in bch2_count_inode_sectors()
96 0, k, ({ in bch2_count_subdirs()
97 if (k.k->type == KEY_TYPE_dirent && in bch2_count_subdirs()
98 bkey_s_c_to_dirent(k).v->d_type == DT_DIR) in bch2_count_subdirs()
121 struct bkey_s_c k; in lookup_first_inode() local
125 BTREE_ITER_all_snapshots, k, ret) { in lookup_first_inode()
126 if (k.k->p.offset != inode_nr) in lookup_first_inode()
128 if (!bkey_is_inode(k.k)) in lookup_first_inode()
130 ret = bch2_inode_unpack(k, inode); in lookup_first_inode()
144 struct bkey_s_c k; in lookup_inode() local
147 k = bch2_bkey_get_iter(trans, &iter, BTREE_ID_inodes, in lookup_inode()
149 ret = bkey_err(k); in lookup_inode()
153 ret = bkey_is_inode(k.k) in lookup_inode()
154 ? bch2_inode_unpack(k, inode) in lookup_inode()
167 struct bkey_s_c k = bch2_hash_lookup_in_snapshot(trans, &iter, bch2_dirent_hash_desc, in lookup_dirent_in_snapshot() local
169 int ret = bkey_err(k); in lookup_dirent_in_snapshot()
341 struct bkey_s_c k = bch2_bkey_get_iter(trans, &iter, BTREE_ID_dirents, in maybe_delete_dirent() local
345 int ret = bkey_err(k); in maybe_delete_dirent()
349 if (bpos_eq(k.k->p, d_pos)) { in maybe_delete_dirent()
354 struct bkey_i *k = bch2_trans_kmalloc(trans, sizeof(*k)); in maybe_delete_dirent() local
355 ret = PTR_ERR_OR_ZERO(k); in maybe_delete_dirent()
359 bkey_init(&k->k); in maybe_delete_dirent()
360 k->k.type = KEY_TYPE_whiteout; in maybe_delete_dirent()
361 k->k.p = iter.pos; in maybe_delete_dirent()
362 ret = bch2_trans_update(trans, &iter, k, BTREE_UPDATE_internal_snapshot_node); in maybe_delete_dirent()
438 struct bkey_s_c k; in reattach_inode() local
444 BTREE_ITER_all_snapshots|BTREE_ITER_intent, k, ret) { in reattach_inode()
445 if (k.k->p.offset != inode->bi_inum) in reattach_inode()
448 if (!bkey_is_inode(k.k) || in reattach_inode()
449 !bch2_snapshot_is_ancestor(c, k.k->p.snapshot, inode->bi_snapshot) || in reattach_inode()
450 snapshot_list_has_ancestor(c, &whiteouts_done, k.k->p.snapshot)) in reattach_inode()
454 bch2_inode_unpack(k, &child_inode); in reattach_inode()
460 k.k->p.snapshot); in reattach_inode()
464 ret = snapshot_list_add(c, &whiteouts_done, k.k->p.snapshot); in reattach_inode()
468 iter.snapshot = k.k->p.snapshot; in reattach_inode()
499 __remove_dirent(trans, d.k->p); in remove_backpointer()
510 (subvol_inum) { s.k->p.offset, le64_to_cpu(s.v->inode) }, in reattach_subvol()
568 new_subvol->k.p.offset = subvolid; in reconstruct_subvol()
616 struct bkey_s_c k = bch2_btree_iter_peek_prev(&iter); in reconstruct_inode() local
618 int ret = bkey_err(k); in reconstruct_inode()
622 i_size = k.k->p.offset << 9; in reconstruct_inode()
804 .snapshot = inode.k->p.snapshot, in add_inode()
813 struct bkey_s_c k; in get_inodes_all_snapshots() local
826 BTREE_ITER_all_snapshots, k, ret) { in get_inodes_all_snapshots()
827 if (k.k->p.offset != inum) in get_inodes_all_snapshots()
830 if (bkey_is_inode(k.k)) in get_inodes_all_snapshots()
831 add_inode(c, w, k); in get_inodes_all_snapshots()
844 lookup_inode_for_snapshot(struct bch_fs *c, struct inode_walker *w, struct bkey_s_c k) in lookup_inode_for_snapshot() argument
846 bool is_whiteout = k.k->type == KEY_TYPE_whiteout; in lookup_inode_for_snapshot()
850 if (bch2_snapshot_is_ancestor(c, k.k->p.snapshot, i->snapshot)) in lookup_inode_for_snapshot()
855 BUG_ON(k.k->p.snapshot > i->snapshot); in lookup_inode_for_snapshot()
857 if (k.k->p.snapshot != i->snapshot && !is_whiteout) { in lookup_inode_for_snapshot()
860 new.snapshot = k.k->p.snapshot; in lookup_inode_for_snapshot()
864 bch2_bkey_val_to_text(&buf, c, k); in lookup_inode_for_snapshot()
869 w->last_pos.inode, k.k->p.snapshot, i->snapshot, buf.buf); in lookup_inode_for_snapshot()
872 while (i > w->inodes.data && i[-1].snapshot > k.k->p.snapshot) in lookup_inode_for_snapshot()
888 struct bkey_s_c k) in walk_inode() argument
890 if (w->last_pos.inode != k.k->p.inode) { in walk_inode()
891 int ret = get_inodes_all_snapshots(trans, w, k.k->p.inode); in walk_inode()
896 w->last_pos = k.k->p; in walk_inode()
898 return lookup_inode_for_snapshot(trans->c, w, k); in walk_inode()
908 struct bkey_s_c k; in get_visible_inodes() local
914 BTREE_ITER_all_snapshots, k, ret) { in get_visible_inodes()
915 if (k.k->p.offset != inum) in get_visible_inodes()
918 if (!ref_visible(c, s, s->pos.snapshot, k.k->p.snapshot)) in get_visible_inodes()
921 if (bkey_is_inode(k.k)) in get_visible_inodes()
922 add_inode(c, w, k); in get_visible_inodes()
924 if (k.k->p.snapshot >= s->pos.snapshot) in get_visible_inodes()
943 struct bkey_s_c k = bch2_bkey_get_iter(trans, &iter, BTREE_ID_inodes, in dirent_has_target() local
944 SPOS(0, le64_to_cpu(d.v->d_inum), d.k->p.snapshot), 0); in dirent_has_target()
945 int ret = bkey_err(k); in dirent_has_target()
949 ret = bkey_is_inode(k.k); in dirent_has_target()
966 if (bkey_val_bytes(k1.k) == bkey_val_bytes(k2.k) && in hash_pick_winner()
967 !memcmp(k1.v, k2.v, bkey_val_bytes(k1.k))) in hash_pick_winner()
996 if (new->k.type != KEY_TYPE_dirent) in fsck_update_backpointers()
1011 i->inode.bi_dir_offset = d->k.p.offset; in fsck_update_backpointers()
1029 struct bkey_i_dirent *new = bch2_trans_kmalloc(trans, bkey_bytes(old.k) + 32); in fsck_rename_dirent()
1036 new->k.p = old.k->p; in fsck_rename_dirent()
1046 new->k.u64s = u64s; in fsck_rename_dirent()
1049 (subvol_inum) { 0, old.k->p.inode }, in fsck_rename_dirent()
1050 old.k->p.snapshot, &new->k_i, in fsck_rename_dirent()
1071 struct bkey_s_c k; in hash_check_key() local
1075 if (hash_k.k->type != desc.key_type) in hash_check_key()
1080 if (likely(hash == hash_k.k->p.offset)) in hash_check_key()
1083 if (hash_k.k->p.offset < hash) in hash_check_key()
1087 SPOS(hash_k.k->p.inode, hash, hash_k.k->p.snapshot), in hash_check_key()
1088 BTREE_ITER_slots, k, ret) { in hash_check_key()
1089 if (bkey_eq(k.k->p, hash_k.k->p)) in hash_check_key()
1092 if (k.k->type == desc.key_type && in hash_check_key()
1093 !desc.cmp_bkey(k, hash_k)) in hash_check_key()
1096 if (bkey_deleted(k.k)) { in hash_check_key()
1108 bch2_btree_id_str(desc.btree_id), hash_k.k->p.inode, hash_k.k->p.offset, hash, in hash_check_key()
1115 k = bch2_hash_set_or_get_in_snapshot(trans, &iter, desc, hash_info, in hash_check_key()
1116 (subvol_inum) { 0, hash_k.k->p.inode }, in hash_check_key()
1117 hash_k.k->p.snapshot, new, in hash_check_key()
1121 ret = bkey_err(k); in hash_check_key()
1124 if (k.k) in hash_check_key()
1137 ret = hash_pick_winner(trans, desc, hash_info, hash_k, k); in hash_check_key()
1147 bch2_bkey_val_to_text(&buf, c, k), in hash_check_key()
1185 return ((struct bkey_s_c_dirent) { .k = ERR_PTR(ret) }); in inode_get_dirent()
1194 struct bkey_s_c k = bch2_bkey_get_iter(trans, &iter, BTREE_ID_deleted_inodes, p, 0); in check_inode_deleted_list() local
1195 int ret = bkey_err(k) ?: k.k->type == KEY_TYPE_set; in check_inode_deleted_list()
1248 struct bkey_s_c k; in get_snapshot_root_inode() local
1253 BTREE_ITER_all_snapshots, k, ret) { in get_snapshot_root_inode()
1254 if (k.k->p.offset != inum) in get_snapshot_root_inode()
1256 if (bkey_is_inode(k.k)) in get_snapshot_root_inode()
1263 BUG_ON(bch2_inode_unpack(k, root)); in get_snapshot_root_inode()
1271 struct bkey_s_c k, in check_inode() argument
1281 ret = bch2_check_key_has_snapshot(trans, iter, k); in check_inode()
1287 ret = snapshots_seen_update(c, s, iter->btree_id, k.k->p); in check_inode()
1291 if (!bkey_is_inode(k.k)) in check_inode()
1294 BUG_ON(bch2_inode_unpack(k, &u)); in check_inode()
1330 ret = bch2_empty_dir_snapshot(trans, k.k->p.offset, 0, k.k->p.snapshot); in check_inode()
1344 ret = bch2_inode_has_child_snapshots(trans, k.k->p); in check_inode()
1376 ret = check_inode_deleted_list(trans, k.k->p); in check_inode()
1383 u.bi_inum, k.k->p.snapshot); in check_inode()
1385 ret = bch2_btree_bit_mod_buffered(trans, BTREE_ID_deleted_inodes, k.k->p, 1); in check_inode()
1389 ret = bch2_inode_or_descendents_is_open(trans, k.k->p); in check_inode()
1410 u.bi_inum, k.k->p.snapshot, u.bi_subvol, u.bi_parent_subvol)) { in check_inode()
1423 ret = reconstruct_subvol(trans, k.k->p.snapshot, u.bi_subvol, u.bi_inum); in check_inode()
1430 u.bi_inum, k.k->p.snapshot, u.bi_subvol) || in check_inode()
1433 k.k->p.snapshot), in check_inode()
1436 u.bi_inum, k.k->p.snapshot, u.bi_subvol, in check_inode()
1469 BTREE_ITER_prefetch|BTREE_ITER_all_snapshots, k, in bch2_check_inodes()
1471 check_inode(trans, &iter, k, &snapshot_root, &s))); in bch2_check_inodes()
1483 struct bkey_s_c k; in find_oldest_inode_needs_reattach() local
1494 BTREE_ITER_all_snapshots, k, ret) { in find_oldest_inode_needs_reattach()
1495 if (k.k->p.offset != inode->bi_inum) in find_oldest_inode_needs_reattach()
1498 if (!bch2_snapshot_is_ancestor(c, inode->bi_snapshot, k.k->p.snapshot)) in find_oldest_inode_needs_reattach()
1501 if (!bkey_is_inode(k.k)) in find_oldest_inode_needs_reattach()
1505 bch2_inode_unpack(k, &parent_inode); in find_oldest_inode_needs_reattach()
1519 struct bkey_s_c k) in check_unreachable_inode() argument
1524 if (!bkey_is_inode(k.k)) in check_unreachable_inode()
1528 BUG_ON(bch2_inode_unpack(k, &inode)); in check_unreachable_inode()
1562 BTREE_ITER_prefetch|BTREE_ITER_all_snapshots, k, in bch2_check_unreachable_inodes()
1564 check_unreachable_inode(trans, &iter, k))); in bch2_check_unreachable_inodes()
1587 struct bkey_s_c k) in check_key_has_inode() argument
1595 if (k.k->type == KEY_TYPE_whiteout) in check_key_has_inode()
1599 ret = reconstruct_inode(trans, iter->btree_id, k.k->p.snapshot, k.k->p.inode) ?: in check_key_has_inode()
1613 bch2_bkey_val_to_text(&buf, c, k), buf.buf))) in check_key_has_inode()
1621 bch2_bkey_val_to_text(&buf, c, k), buf.buf))) in check_key_has_inode()
1710 struct bkey_s_c k) in extent_ends_at() argument
1713 .offset = k.k->p.offset, in extent_ends_at()
1714 .snapshot = k.k->p.snapshot, in extent_ends_at()
1725 if (i->snapshot == k.k->p.snapshot) { in extent_ends_at()
1731 if (i->snapshot >= k.k->p.snapshot) in extent_ends_at()
1764 if (!bpos_eq(pos1, k1.k->p)) { in overlapping_extents_found()
1786 if (bpos_ge(k2.k->p, pos2.p)) in overlapping_extents_found()
1793 if (bpos_gt(k2.k->p, pos2.p) || in overlapping_extents_found()
1794 pos2.size != k2.k->size) { in overlapping_extents_found()
1857 struct bkey_s_c k, in check_overlapping_extents() argument
1865 if (bpos_eq(extent_ends->last_pos, k.k->p)) in check_overlapping_extents()
1868 if (extent_ends->last_pos.inode != k.k->p.inode) in check_overlapping_extents()
1872 if (i->offset <= bkey_start_offset(k.k)) in check_overlapping_extents()
1876 k.k->p.snapshot, seen, in check_overlapping_extents()
1885 *k.k, fixed, i); in check_overlapping_extents()
1890 extent_ends->last_pos = k.k->p; in check_overlapping_extents()
1896 struct bkey_s_c k) in check_extent_overbig() argument
1899 struct bkey_ptrs_c ptrs = bch2_bkey_ptrs_c(k); in check_extent_overbig()
1904 bkey_for_each_crc(k.k, ptrs, crc, i) in check_extent_overbig()
1909 bch2_bkey_val_to_text(&buf, c, k); in check_extent_overbig()
1918 struct bkey_s_c k, in check_extent() argument
1928 ret = bch2_check_key_has_snapshot(trans, iter, k); in check_extent()
1934 if (inode->last_pos.inode != k.k->p.inode && inode->have_inodes) { in check_extent()
1940 ret = snapshots_seen_update(c, s, iter->btree_id, k.k->p); in check_extent()
1944 struct inode_walker_entry *extent_i = walk_inode(trans, inode, k); in check_extent()
1949 ret = check_key_has_inode(trans, iter, inode, extent_i, k); in check_extent()
1953 if (k.k->type != KEY_TYPE_whiteout) { in check_extent()
1954 ret = check_overlapping_extents(trans, s, extent_ends, k, iter, in check_extent()
1967 if (i->snapshot > k.k->p.snapshot || in check_extent()
1968 !key_visible_in_snapshot(c, s, i->snapshot, k.k->p.snapshot)) in check_extent()
1971 if (fsck_err_on(k.k->p.offset > round_up(i->inode.bi_size, block_bytes(c)) >> 9 && in check_extent()
1972 !bkey_extent_is_reservation(k), in check_extent()
1976 (bch2_bkey_val_to_text(&buf, c, k), buf.buf))) { in check_extent()
1988 iter->k.type = KEY_TYPE_whiteout; in check_extent()
1998 if (bkey_extent_is_allocation(k.k)) { in check_extent()
2002 if (i->snapshot > k.k->p.snapshot || in check_extent()
2003 !key_visible_in_snapshot(c, s, i->snapshot, k.k->p.snapshot)) in check_extent()
2006 i->count += k.k->size; in check_extent()
2010 if (k.k->type != KEY_TYPE_whiteout) { in check_extent()
2011 ret = extent_ends_at(c, extent_ends, s, k); in check_extent()
2040 BTREE_ITER_prefetch|BTREE_ITER_all_snapshots, k, ({ in bch2_check_extents()
2042 check_extent(trans, &iter, k, &w, &s, &extent_ends, &res) ?: in bch2_check_extents()
2043 check_extent_overbig(trans, &iter, k); in bch2_check_extents()
2063 BTREE_ITER_prefetch, k, in bch2_check_indirect_extents()
2067 check_extent_overbig(trans, &iter, k); in bch2_check_indirect_extents()
2154 target->bi_dir = d.k->p.inode; in check_dirent_inode_dirent()
2155 target->bi_dir_offset = d.k->p.offset; in check_dirent_inode_dirent()
2185 d.k->p.inode, in check_dirent_inode_dirent()
2186 d.k->p.offset)) { in check_dirent_inode_dirent()
2187 target->bi_dir = d.k->p.inode; in check_dirent_inode_dirent()
2188 target->bi_dir_offset = d.k->p.offset; in check_dirent_inode_dirent()
2205 ret = __remove_dirent(trans, d.k->p); in check_dirent_inode_dirent()
2255 n = bch2_trans_kmalloc(trans, bkey_bytes(d.k)); in check_dirent_target()
2286 struct bkey_s_c k; in find_snapshot_subvol() local
2289 for_each_btree_key_norestart(trans, iter, BTREE_ID_subvolumes, POS_MIN, 0, k, ret) { in find_snapshot_subvol()
2290 if (k.k->type != KEY_TYPE_subvolume) in find_snapshot_subvol()
2293 struct bkey_s_c_subvolume s = bkey_s_c_to_subvolume(k); in find_snapshot_subvol()
2296 *subvolid = k.k->p.offset; in find_snapshot_subvol()
2327 (!ret && !bch2_snapshot_is_ancestor(c, parent_snapshot, d.k->p.snapshot))) { in check_dirent_to_subvol()
2328 int ret2 = find_snapshot_subvol(trans, d.k->p.snapshot, &new_parent_subvol); in check_dirent_to_subvol()
2340 ret = reconstruct_subvol(trans, d.k->p.snapshot, parent_subvol, 0); in check_dirent_to_subvol()
2344 parent_snapshot = d.k->p.snapshot; in check_dirent_to_subvol()
2351 fsck_err_on(!ret && !bch2_snapshot_is_ancestor(c, parent_snapshot, d.k->p.snapshot), in check_dirent_to_subvol()
2357 bch_err(c, "could not find a subvol for snapshot %u", d.k->p.snapshot); in check_dirent_to_subvol()
2381 return __remove_dirent(trans, d.k->p); in check_dirent_to_subvol()
2437 struct bkey_s_c k, in check_dirent() argument
2448 ret = bch2_check_key_has_snapshot(trans, iter, k); in check_dirent()
2454 ret = snapshots_seen_update(c, s, iter->btree_id, k.k->p); in check_dirent()
2458 if (k.k->type == KEY_TYPE_whiteout) in check_dirent()
2461 if (dir->last_pos.inode != k.k->p.inode && dir->have_inodes) { in check_dirent()
2467 i = walk_inode(trans, dir, k); in check_dirent()
2472 ret = check_key_has_inode(trans, iter, dir, i, k); in check_dirent()
2483 ret = hash_check_key(trans, s, bch2_dirent_hash_desc, hash_info, iter, k); in check_dirent()
2492 if (k.k->type != KEY_TYPE_dirent) in check_dirent()
2495 struct bkey_s_c_dirent d = bkey_s_c_to_dirent(k); in check_dirent()
2510 bch2_bkey_val_to_text(&buf, c, k), in check_dirent()
2512 ret = __remove_dirent(trans, d.k->p); in check_dirent()
2529 for_each_visible_inode(c, s, dir, d.k->p.snapshot, i) in check_dirent()
2555 BTREE_ITER_prefetch|BTREE_ITER_all_snapshots, k, in bch2_check_dirents()
2556 check_dirent(trans, &iter, k, &hash_info, &dir, &target, &s)) ?: in bch2_check_dirents()
2567 struct bkey_s_c k, in check_xattr() argument
2575 ret = bch2_check_key_has_snapshot(trans, iter, k); in check_xattr()
2581 i = walk_inode(trans, inode, k); in check_xattr()
2586 ret = check_key_has_inode(trans, iter, inode, i, k); in check_xattr()
2597 ret = hash_check_key(trans, NULL, bch2_xattr_hash_desc, hash_info, iter, k); in check_xattr()
2615 k, in bch2_check_xattrs()
2618 check_xattr(trans, &iter, k, &hash_info, &inode))); in bch2_check_xattrs()
2649 root_subvol->k.p.offset = BCACHEFS_ROOT_SUBVOL; in check_root_trans()
2701 static int check_subvol_path(struct btree_trans *trans, struct btree_iter *iter, struct bkey_s_c k) in check_subvol_path() argument
2709 if (k.k->type != KEY_TYPE_subvolume) in check_subvol_path()
2712 while (k.k->p.offset != BCACHEFS_ROOT_SUBVOL) { in check_subvol_path()
2713 ret = darray_push(&subvol_path, k.k->p.offset); in check_subvol_path()
2717 struct bkey_s_c_subvolume s = bkey_s_c_to_subvolume(k); in check_subvol_path()
2721 (subvol_inum) { s.k->p.offset, le64_to_cpu(s.v->inode) }, in check_subvol_path()
2737 k = bch2_btree_iter_peek_slot(&parent_iter); in check_subvol_path()
2738 ret = bkey_err(k); in check_subvol_path()
2742 if (fsck_err_on(k.k->type != KEY_TYPE_subvolume, in check_subvol_path()
2763 BTREE_ID_subvolumes, POS_MIN, BTREE_ITER_prefetch, k, in bch2_check_subvolume_structure()
2765 check_subvol_path(trans, &iter, k))); in bch2_check_subvolume_structure()
2792 u32 snapshot = inode_k.k->p.snapshot; in check_path()
2838 !bkey_is_inode(inode_k.k) ? -BCH_ERR_ENOENT_inode in check_path()
2846 snapshot = inode_k.k->p.snapshot; in check_path()
2889 BTREE_ITER_all_snapshots, k, in bch2_check_directory_structure()
2891 if (!bkey_is_inode(k.k)) in bch2_check_directory_structure()
2894 if (bch2_inode_flags(k) & BCH_INODE_unlinked) in bch2_check_directory_structure()
2897 check_path(trans, &path, k); in bch2_check_directory_structure()
2991 BTREE_ITER_all_snapshots, k, ({ in check_nlinks_find_hardlinks()
2992 if (!bkey_is_inode(k.k)) in check_nlinks_find_hardlinks()
2997 BUG_ON(bch2_inode_unpack(k, &u)); in check_nlinks_find_hardlinks()
3013 ret = add_nlink(c, t, k.k->p.offset, k.k->p.snapshot); in check_nlinks_find_hardlinks()
3015 *end = k.k->p.offset; in check_nlinks_find_hardlinks()
3038 BTREE_ITER_all_snapshots, k, ({ in check_nlinks_walk_dirents()
3039 ret = snapshots_seen_update(c, &s, iter.btree_id, k.k->p); in check_nlinks_walk_dirents()
3043 if (k.k->type == KEY_TYPE_dirent) { in check_nlinks_walk_dirents()
3044 struct bkey_s_c_dirent d = bkey_s_c_to_dirent(k); in check_nlinks_walk_dirents()
3049 le64_to_cpu(d.v->d_inum), d.k->p.snapshot); in check_nlinks_walk_dirents()
3061 struct bkey_s_c k, in check_nlinks_update_inode() argument
3069 if (k.k->p.offset >= range_end) in check_nlinks_update_inode()
3072 if (!bkey_is_inode(k.k)) in check_nlinks_update_inode()
3075 BUG_ON(bch2_inode_unpack(k, &u)); in check_nlinks_update_inode()
3083 while ((cmp_int(link->inum, k.k->p.offset) ?: in check_nlinks_update_inode()
3084 cmp_int(link->snapshot, k.k->p.snapshot)) < 0) { in check_nlinks_update_inode()
3111 BTREE_ITER_intent|BTREE_ITER_prefetch|BTREE_ITER_all_snapshots, k, in check_nlinks_update_hardlinks()
3113 check_nlinks_update_inode(trans, &iter, k, links, &idx, range_end))); in check_nlinks_update_hardlinks()
3157 struct bkey_s_c k) in fix_reflink_p_key() argument
3162 if (k.k->type != KEY_TYPE_reflink_p) in fix_reflink_p_key()
3165 p = bkey_s_c_to_reflink_p(k); in fix_reflink_p_key()
3175 bkey_reassemble(&u->k_i, k); in fix_reflink_p_key()
3191 BTREE_ITER_all_snapshots, k, in bch2_fix_reflink_p()
3193 fix_reflink_p_key(trans, &iter, k))); in bch2_fix_reflink_p()