Lines Matching refs:entry
88 * This makes the size of a cache entry to be exactly 192 bytes on x86_64, which
105 * A backref cache entry maps a leaf to a list of IDs of roots from which the
107 * With SEND_MAX_BACKREF_CACHE_ROOTS as 12, each cache entry is 128 bytes (on
111 struct btrfs_lru_cache_entry entry;
118 static_assert(offsetof(struct backref_cache_entry, entry) == 0);
342 * The key in the entry is an inode number, and the generation matches
345 struct btrfs_lru_cache_entry entry;
355 static_assert(offsetof(struct name_cache_entry, entry) == 0);
1407 struct backref_cache_entry *entry;
1432 entry = container_of(raw_entry, struct backref_cache_entry, entry);
1433 *root_ids_ret = entry->root_ids;
1434 *root_count_ret = entry->num_roots;
1460 new_entry->entry.key = leaf_bytenr >> fs_info->sectorsize_bits;
1461 new_entry->entry.gen = 0;
1485 * We may have not added any roots to the new cache entry, which means
1487 * allowed to clone. Cache the new entry as it's still useful to avoid
1493 ret = btrfs_lru_cache_store(&sctx->backref_cache, &new_entry->entry,
2014 * generation of the parent dir and the name of the dir entry.
2139 * and we can just unlink this entry.
2282 struct btrfs_lru_cache_entry *entry;
2284 entry = btrfs_lru_cache_lookup(&sctx->name_cache, ino, gen);
2285 if (!entry)
2288 return container_of(entry, struct name_cache_entry, entry);
2311 * ino/gen. If yes, check if the cache entry is still up-to-date. If yes
2317 btrfs_lru_cache_remove(&sctx->name_cache, &nce->entry);
2386 nce->entry.key = ino;
2387 nce->entry.gen = gen;
2399 nce_ret = btrfs_lru_cache_store(&sctx->name_cache, &nce->entry, GFP_KERNEL);
2785 struct btrfs_lru_cache_entry *entry;
2788 entry = btrfs_lru_cache_lookup(&sctx->dir_utimes_cache, dir, gen);
2789 if (entry != NULL)
2793 entry = kmalloc(sizeof(*entry), GFP_KERNEL);
2794 if (!entry)
2797 entry->key = dir;
2798 entry->gen = gen;
2800 ret = btrfs_lru_cache_store(&sctx->dir_utimes_cache, entry, GFP_KERNEL);
2803 kfree(entry);
2920 struct btrfs_lru_cache_entry *entry;
2924 entry = kmalloc(sizeof(*entry), GFP_KERNEL);
2925 if (!entry)
2928 entry->key = dir;
2929 entry->gen = 0;
2930 ret = btrfs_lru_cache_store(&sctx->dir_created_cache, entry, GFP_KERNEL);
2932 kfree(entry);
3116 struct orphan_dir_info *entry, *odi;
3120 entry = rb_entry(parent, struct orphan_dir_info, node);
3121 if (dir_ino < entry->ino)
3123 else if (dir_ino > entry->ino)
3125 else if (dir_gen < entry->gen)
3127 else if (dir_gen > entry->gen)
3130 return entry;
3150 struct orphan_dir_info *entry;
3153 entry = rb_entry(n, struct orphan_dir_info, node);
3154 if (dir_ino < entry->ino)
3156 else if (dir_ino > entry->ino)
3158 else if (gen < entry->gen)
3160 else if (gen > entry->gen)
3163 return entry;
3220 * entry. This is very likely the inode with the highest number
3221 * of all inodes that have an entry in the directory. We can
3323 struct waiting_dir_move *entry = get_waiting_dir_move(sctx, ino);
3325 return entry != NULL;
3332 struct waiting_dir_move *entry, *dm;
3344 entry = rb_entry(parent, struct waiting_dir_move, node);
3345 if (ino < entry->ino) {
3347 } else if (ino > entry->ino) {
3364 struct waiting_dir_move *entry;
3367 entry = rb_entry(n, struct waiting_dir_move, node);
3368 if (ino < entry->ino)
3370 else if (ino > entry->ino)
3373 return entry;
3397 struct pending_dir_move *entry = NULL, *pm;
3414 entry = rb_entry(parent, struct pending_dir_move, node);
3415 if (parent_ino < entry->parent_ino) {
3417 } else if (parent_ino > entry->parent_ino) {
3441 list_add_tail(&pm->list, &entry->list);
3459 struct pending_dir_move *entry;
3462 entry = rb_entry(n, struct pending_dir_move, node);
3463 if (parent_ino < entry->parent_ino)
3465 else if (parent_ino > entry->parent_ino)
3468 return entry;
4327 &nce->entry);
4646 const struct recorded_ref *entry = rb_entry(node, struct recorded_ref, node);
4648 return rbtree_ref_comp(entry, parent) < 0;
8083 struct btrfs_lru_cache_entry *entry;
8178 * is slow to remove the directory entry, send can still be started
8325 btrfs_lru_cache_for_each_entry_safe(&sctx->dir_utimes_cache, entry, tmp) {
8326 ret = send_utimes(sctx, entry->key, entry->gen);
8329 btrfs_lru_cache_remove(&sctx->dir_utimes_cache, entry);