• Home
  • Raw
  • Download

Lines Matching refs:key

24 nilfs_direct_get_ptr(const struct nilfs_bmap *direct, __u64 key)  in nilfs_direct_get_ptr()  argument
26 return le64_to_cpu(*(nilfs_direct_dptrs(direct) + key)); in nilfs_direct_get_ptr()
30 __u64 key, __u64 ptr) in nilfs_direct_set_ptr() argument
32 *(nilfs_direct_dptrs(direct) + key) = cpu_to_le64(ptr); in nilfs_direct_set_ptr()
36 __u64 key, int level, __u64 *ptrp) in nilfs_direct_lookup() argument
40 if (key > NILFS_DIRECT_KEY_MAX || level != 1) in nilfs_direct_lookup()
42 ptr = nilfs_direct_get_ptr(direct, key); in nilfs_direct_lookup()
51 __u64 key, __u64 *ptrp, in nilfs_direct_lookup_contig() argument
59 if (key > NILFS_DIRECT_KEY_MAX) in nilfs_direct_lookup_contig()
61 ptr = nilfs_direct_get_ptr(direct, key); in nilfs_direct_lookup_contig()
74 NILFS_DIRECT_KEY_MAX - key + 1); in nilfs_direct_lookup_contig()
76 (ptr2 = nilfs_direct_get_ptr(direct, key + cnt)) != in nilfs_direct_lookup_contig()
93 nilfs_direct_find_target_v(const struct nilfs_bmap *direct, __u64 key) in nilfs_direct_find_target_v() argument
97 ptr = nilfs_bmap_find_target_seq(direct, key); in nilfs_direct_find_target_v()
106 static int nilfs_direct_insert(struct nilfs_bmap *bmap, __u64 key, __u64 ptr) in nilfs_direct_insert() argument
113 if (key > NILFS_DIRECT_KEY_MAX) in nilfs_direct_insert()
115 if (nilfs_direct_get_ptr(bmap, key) != NILFS_BMAP_INVALID_PTR) in nilfs_direct_insert()
119 req.bpr_ptr = nilfs_direct_find_target_v(bmap, key); in nilfs_direct_insert()
129 nilfs_direct_set_ptr(bmap, key, req.bpr_ptr); in nilfs_direct_insert()
135 nilfs_bmap_set_target_v(bmap, key, req.bpr_ptr); in nilfs_direct_insert()
142 static int nilfs_direct_delete(struct nilfs_bmap *bmap, __u64 key) in nilfs_direct_delete() argument
148 if (key > NILFS_DIRECT_KEY_MAX || in nilfs_direct_delete()
149 nilfs_direct_get_ptr(bmap, key) == NILFS_BMAP_INVALID_PTR) in nilfs_direct_delete()
153 req.bpr_ptr = nilfs_direct_get_ptr(bmap, key); in nilfs_direct_delete()
158 nilfs_direct_set_ptr(bmap, key, NILFS_BMAP_INVALID_PTR); in nilfs_direct_delete()
167 __u64 key; in nilfs_direct_seek_key() local
169 for (key = start; key <= NILFS_DIRECT_KEY_MAX; key++) { in nilfs_direct_seek_key()
170 if (nilfs_direct_get_ptr(direct, key) != in nilfs_direct_seek_key()
172 *keyp = key; in nilfs_direct_seek_key()
181 __u64 key, lastkey; in nilfs_direct_last_key() local
184 for (key = NILFS_DIRECT_KEY_MIN; key <= NILFS_DIRECT_KEY_MAX; key++) in nilfs_direct_last_key()
185 if (nilfs_direct_get_ptr(direct, key) != in nilfs_direct_last_key()
187 lastkey = key; in nilfs_direct_last_key()
197 static int nilfs_direct_check_insert(const struct nilfs_bmap *bmap, __u64 key) in nilfs_direct_check_insert() argument
199 return key > NILFS_DIRECT_KEY_MAX; in nilfs_direct_check_insert()
205 __u64 key; in nilfs_direct_gather_data() local
212 for (key = 0; key < nitems; key++) { in nilfs_direct_gather_data()
213 ptr = nilfs_direct_get_ptr(direct, key); in nilfs_direct_gather_data()
215 keys[n] = key; in nilfs_direct_gather_data()
224 __u64 key, __u64 *keys, __u64 *ptrs, int n) in nilfs_direct_delete_and_convert() argument
232 ret = bmap->b_ops->bop_delete(bmap, key); in nilfs_direct_delete_and_convert()
244 dptrs[i] = (i != key) ? in nilfs_direct_delete_and_convert()
261 __u64 key; in nilfs_direct_propagate() local
269 key = nilfs_bmap_data_get_key(bmap, bh); in nilfs_direct_propagate()
270 ptr = nilfs_direct_get_ptr(bmap, key); in nilfs_direct_propagate()
280 nilfs_direct_set_ptr(bmap, key, newreq.pr_entry_nr); in nilfs_direct_propagate()
288 __u64 key, __u64 ptr, in nilfs_direct_assign_v() argument
302 binfo->bi_v.bi_blkoff = cpu_to_le64(key); in nilfs_direct_assign_v()
308 __u64 key, __u64 ptr, in nilfs_direct_assign_p() argument
313 nilfs_direct_set_ptr(direct, key, blocknr); in nilfs_direct_assign_p()
315 binfo->bi_dat.bi_blkoff = cpu_to_le64(key); in nilfs_direct_assign_p()
326 __u64 key; in nilfs_direct_assign() local
329 key = nilfs_bmap_data_get_key(bmap, *bh); in nilfs_direct_assign()
330 if (unlikely(key > NILFS_DIRECT_KEY_MAX)) { in nilfs_direct_assign()
334 bmap->b_inode->i_ino, (unsigned long long)key); in nilfs_direct_assign()
337 ptr = nilfs_direct_get_ptr(bmap, key); in nilfs_direct_assign()
347 nilfs_direct_assign_v(bmap, key, ptr, bh, blocknr, binfo) : in nilfs_direct_assign()
348 nilfs_direct_assign_p(bmap, key, ptr, bh, blocknr, binfo); in nilfs_direct_assign()