Lines Matching full:blk

56 static ssize_t read_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf)
62 info->dqi_usable_bs, (loff_t)blk << info->dqi_blocksize_bits);
65 static ssize_t write_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf)
71 info->dqi_usable_bs, (loff_t)blk << info->dqi_blocksize_bits);
119 int ret, blk;
124 blk = info->dqi_free_blk;
125 ret = read_blk(info, blk, buf);
139 blk = info->dqi_blocks++;
142 ret = blk;
149 static int put_free_dqblk(struct qtree_mem_dqinfo *info, char *buf, uint blk)
157 err = write_blk(info, blk, buf);
160 info->dqi_free_blk = blk;
167 uint blk)
203 if (write_blk(info, blk, buf) < 0)
205 "with free entries", blk);
214 uint blk)
224 err = write_blk(info, blk, buf);
232 cpu_to_le32(blk);
238 info->dqi_free_entry = blk;
262 uint blk, i;
274 blk = info->dqi_free_entry;
275 *err = read_blk(info, blk, buf);
282 blk = get_free_dqblk(info);
283 if ((int)blk < 0) {
284 *err = blk;
291 info->dqi_free_entry = blk;
296 *err = remove_free_dqentry(info, buf, blk);
299 "from entry free list", blk);
318 *err = write_blk(info, blk, buf);
321 blk);
324 dquot->dq_off = ((loff_t)blk << info->dqi_blocksize_bits) +
328 return blk;
480 uint blk)
488 if (dquot->dq_off >> info->dqi_blocksize_bits != blk) {
490 "other block (%u) than it should (%u)", blk,
495 ret = read_blk(info, blk, buf);
498 blk);
507 ret = remove_free_dqentry(info, buf, blk);
509 ret = put_free_dqblk(info, buf, blk);
512 "(%u) to free list", blk);
522 ret = insert_free_dqentry(info, buf, blk);
525 "data block (%u) to free entry list", blk);
529 ret = write_blk(info, blk, buf);
532 "data block %u", blk);
623 struct dquot *dquot, uint blk)
632 ret = read_blk(info, blk, buf);
635 "block %u", blk);
651 ret = ((loff_t)blk << info->dqi_blocksize_bits) + sizeof(struct
666 uint blk;
678 blk = le32_to_cpu(ref[get_index(info, dquot->dq_id, depth)]);
679 if (!blk) /* No reference? */
681 ret = do_check_range(dquot->dq_sb, "block", blk, QT_TREEOFF,
688 if (blk == blks[i]) {
696 blks[depth + 1] = blk;
700 ret = find_block_dqentry(info, dquot, blk);
793 unsigned int blk, int depth)
808 ret = read_blk(info, blk, buf);
811 "Can't read quota tree block %u", blk);