Lines Matching +full:9 +full:k

35 	struct bkey_s_c k;  in bch2_extent_fallocate()  local
46 k = bch2_btree_iter_peek_slot(iter); in bch2_extent_fallocate()
47 ret = bkey_err(k); in bch2_extent_fallocate()
51 sectors = min_t(u64, sectors, k.k->p.offset - iter->pos.offset); in bch2_extent_fallocate()
53 (int) bch2_bkey_nr_ptrs_fully_allocated(k)); in bch2_extent_fallocate()
63 bch2_bkey_buf_reassemble(&old, c, k); in bch2_extent_fallocate()
69 reservation = bkey_reservation_init(new.k); in bch2_extent_fallocate()
70 reservation->k.p = iter->pos; in bch2_extent_fallocate()
71 bch2_key_resize(&reservation->k, sectors); in bch2_extent_fallocate()
82 e = bkey_extent_init(new.k); in bch2_extent_fallocate()
83 e->k.p = iter->pos; in bch2_extent_fallocate()
101 bch2_key_resize(&e->k, sectors); in bch2_extent_fallocate()
111 ret = bch2_extent_update(trans, inum, iter, new.k, &disk_res, in bch2_extent_fallocate()
119 iter->pos.offset << 9, in bch2_extent_fallocate()
145 struct bkey_s_c k; in bch2_fpunch_at() local
169 k = bch2_btree_iter_peek_upto(iter, end_pos); in bch2_fpunch_at()
170 if (!k.k) in bch2_fpunch_at()
173 ret = bkey_err(k); in bch2_fpunch_at()
177 bkey_init(&delete.k); in bch2_fpunch_at()
178 delete.k.p = iter->pos; in bch2_fpunch_at()
181 bch2_key_resize(&delete.k, max_sectors); in bch2_fpunch_at()
216 void bch2_logged_op_truncate_to_text(struct printbuf *out, struct bch_fs *c, struct bkey_s_c k) in bch2_logged_op_truncate_to_text() argument
218 struct bkey_s_c_logged_op_truncate op = bkey_s_c_to_logged_op_truncate(k); in bch2_logged_op_truncate_to_text()
260 POS(inum.inum, round_up(new_i_size, block_bytes(c)) >> 9), in __bch2_resume_logged_op_truncate()
308 void bch2_logged_op_finsert_to_text(struct printbuf *out, struct bch_fs *c, struct bkey_s_c k) in bch2_logged_op_finsert_to_text() argument
310 struct bkey_s_c_logged_op_finsert op = bkey_s_c_to_logged_op_finsert(k); in bch2_logged_op_finsert_to_text()
325 offset <<= 9; in adjust_i_size()
326 len <<= 9; in adjust_i_size()
415 struct bkey_s_c k; in __bch2_resume_logged_op_finsert() local
428 k = insert in __bch2_resume_logged_op_finsert()
431 if ((ret = bkey_err(k))) in __bch2_resume_logged_op_finsert()
434 if (!k.k || in __bch2_resume_logged_op_finsert()
435 k.k->p.inode != inum.inum || in __bch2_resume_logged_op_finsert()
436 bkey_le(k.k->p, POS(inum.inum, src_offset))) in __bch2_resume_logged_op_finsert()
439 copy = bch2_bkey_make_mut_noupdate(trans, k); in __bch2_resume_logged_op_finsert()
444 bkey_lt(bkey_start_pos(k.k), src_pos)) { in __bch2_resume_logged_op_finsert()
449 copy->k.size * in __bch2_resume_logged_op_finsert()
454 bkey_init(&delete.k); in __bch2_resume_logged_op_finsert()
455 delete.k.p = copy->k.p; in __bch2_resume_logged_op_finsert()
456 delete.k.p.snapshot = snapshot; in __bch2_resume_logged_op_finsert()
457 delete.k.size = copy->k.size; in __bch2_resume_logged_op_finsert()
459 copy->k.p.offset += shift; in __bch2_resume_logged_op_finsert()
460 copy->k.p.snapshot = snapshot; in __bch2_resume_logged_op_finsert()
462 op->v.pos = cpu_to_le64(insert ? bkey_start_offset(&delete.k) : delete.k.p.offset); in __bch2_resume_logged_op_finsert()