Lines Matching refs:inum

27 static s64 bch2_count_inode_sectors(struct btree_trans *trans, u64 inum,
33 SPOS(inum, 0, snapshot),
34 POS(inum, U64_MAX),
44 static s64 bch2_count_subdirs(struct btree_trans *trans, u64 inum,
50 SPOS(inum, 0, snapshot),
51 POS(inum, U64_MAX),
63 u32 *snapshot, u64 *inum)
69 *inum = le64_to_cpu(s.inode);
176 u64 inum = 0;
209 root_inum.inum = le64_to_cpu(subvol.inode);
214 ret = lookup_inode(trans, root_inum.inum, &root_inode, &root_inode_snapshot);
216 root_inum.inum, le32_to_cpu(st.master_subvol));
223 &lostfound_str, &inum, &d_type, snapshot);
240 ret = lookup_inode(trans, inum, lostfound, &snapshot);
242 inum, snapshot, root_inum.inum, bch2_snapshot_root(c, snapshot));
383 static int reconstruct_subvol(struct btree_trans *trans, u32 snapshotid, u32 subvolid, u64 inum)
393 * If inum isn't set, that means we're being called from check_dirents,
397 if (!inum) {
414 inum = new_inode.bi_inum;
417 bch_info(c, "reconstructing subvol %u with root inode %llu", subvolid, inum);
427 new_subvol->v.inode = cpu_to_le64(inum);
462 static int reconstruct_inode(struct btree_trans *trans, u32 snapshot, u64 inum, u64 size, unsigned mode)
470 new_inode.bi_inum = inum;
475 static int reconstruct_reg_inode(struct btree_trans *trans, u32 snapshot, u64 inum)
479 bch2_trans_iter_init(trans, &iter, BTREE_ID_extents, SPOS(inum, U64_MAX, snapshot), 0);
486 return reconstruct_inode(trans, snapshot, inum, k.k->p.offset << 9, S_IFREG);
654 struct inode_walker *w, u64 inum)
664 for_each_btree_key_norestart(trans, iter, BTREE_ID_inodes, POS(0, inum),
666 if (k.k->p.offset != inum)
745 u64 inum)
754 for_each_btree_key_norestart(trans, iter, BTREE_ID_inodes, POS(0, inum),
756 if (k.k->p.offset != inum)
898 u64 inum;
899 int ret = subvol_lookup(trans, inode->bi_parent_subvol, snapshot, &inum);
1674 bch_err_ratelimited(c, "fsck counted subdirectories wrong for inum %llu:%u: got %llu should be %llu",
2223 u64 inum;
2226 ret = subvol_lookup(trans, BCACHEFS_ROOT_SUBVOL, &snapshot, &inum);
2239 inum = BCACHEFS_ROOT_INO;
2245 root_subvol->v.inode = cpu_to_le64(inum);
2263 root_inode.bi_inum = inum;
2384 u64 inum;
2390 static bool path_is_dup(pathbuf *p, u64 inum, u32 snapshot)
2393 if (i->inum == inum &&
2450 .inum = inode.bi_inum,
2478 pr_err("%llu:%u", i->inum, i->snapshot);
2536 u64 inum;
2543 u64 inum, u32 snapshot)
2565 .inum = inum,
2577 return cmp_int(l->inum, r->inum);
2582 u64 range_start, u64 range_end, u64 inum, u32 snapshot)
2585 .inum = inum, .snapshot = U32_MAX,
2588 if (inum < range_start || inum >= range_end)
2596 while (link > links->d && link[0].inum == link[-1].inum)
2599 for (; link < links->d + links->nr && link->inum == inum; link++)
2706 while ((cmp_int(link->inum, k.k->p.offset) ?: