Lines Matching refs:offs

164 int ubifs_add_bud_to_log(struct ubifs_info *c, int jhead, int lnum, int offs)  in ubifs_add_bud_to_log()  argument
204 if (c->bud_bytes + c->leb_size - offs > c->max_bud_bytes) { in ubifs_add_bud_to_log()
225 bud->start = offs; in ubifs_add_bud_to_log()
231 ref->offs = cpu_to_le32(bud->start); in ubifs_add_bud_to_log()
319 c->cmt_bud_bytes += wbuf->offs - bud->start; in remove_buds()
322 wbuf->offs - bud->start, c->cmt_bud_bytes); in remove_buds()
323 bud->start = wbuf->offs; in remove_buds()
395 int offs = c->jheads[i].wbuf.offs; in ubifs_log_start_commit() local
397 if (lnum == -1 || offs == c->leb_size) in ubifs_log_start_commit()
401 lnum, offs, dbg_jhead(i)); in ubifs_log_start_commit()
405 ref->offs = cpu_to_le32(offs); in ubifs_log_start_commit()
611 static int add_node(struct ubifs_info *c, void *buf, int *lnum, int *offs, in add_node() argument
615 int len = le32_to_cpu(ch->len), remains = c->leb_size - *offs; in add_node()
618 int sz = ALIGN(*offs, c->min_io_size), err; in add_node()
620 ubifs_pad(c, buf + *offs, sz - *offs); in add_node()
625 *offs = 0; in add_node()
627 memcpy(buf + *offs, node, len); in add_node()
628 *offs += ALIGN(len, 8); in add_node()
647 int lnum, err, first = 1, write_lnum, offs = 0; in ubifs_consolidate_log() local
674 &offs, snod->node); in ubifs_consolidate_log()
683 err = add_node(c, buf, &write_lnum, &offs, in ubifs_consolidate_log()
696 if (offs) { in ubifs_consolidate_log()
697 int sz = ALIGN(offs, c->min_io_size); in ubifs_consolidate_log()
699 ubifs_pad(c, buf + offs, sz - offs); in ubifs_consolidate_log()
703 offs = ALIGN(offs, c->min_io_size); in ubifs_consolidate_log()
720 c->lhead_offs = offs; in ubifs_consolidate_log()