Lines Matching refs:buf_offs
416 int lnum, offs, len, next_len, buf_len, buf_offs, used, avail; in layout_in_empty_space() local
424 buf_offs = c->ihead_offs; in layout_in_empty_space()
433 if (buf_offs + next_len > c->leb_size) in layout_in_empty_space()
448 buf_offs = 0; in layout_in_empty_space()
453 offs = buf_offs + used; in layout_in_empty_space()
499 buf_offs + used + next_len <= c->leb_size && in layout_in_empty_space()
504 buf_offs + used + next_len <= c->leb_size) in layout_in_empty_space()
510 buf_offs += blen; in layout_in_empty_space()
512 if (buf_offs + next_len > c->leb_size) { in layout_in_empty_space()
514 c->leb_size - buf_offs, blen - used, in layout_in_empty_space()
526 err = ubifs_update_one_lp(c, lnum, c->leb_size - buf_offs, in layout_in_empty_space()
534 c->dbg->new_ihead_offs = buf_offs; in layout_in_empty_space()
810 int i, lnum, offs, len, next_len, buf_len, buf_offs, used; in write_index() local
822 buf_offs = c->ihead_offs; in write_index()
831 if (buf_offs + next_len > c->leb_size) { in write_index()
870 buf_offs = 0; in write_index()
874 offs = buf_offs + used; in write_index()
939 nxt_offs = buf_offs + used + next_len; in write_index()
952 err = ubifs_leb_write(c, lnum, c->cbuf, buf_offs, blen); in write_index()
955 buf_offs += blen; in write_index()
975 buf_offs != c->dbg->new_ihead_offs) { in write_index()
981 c->ihead_offs = buf_offs; in write_index()