Home
last modified time | relevance | path

Searched refs:offs (Results 1 – 25 of 44) sorted by relevance

12

/fs/ubifs/
Dscan.c70 int offs, int quiet) in ubifs_scan_a_node() argument
78 dbg_scan("hit empty space at LEB %d:%d", lnum, offs); in ubifs_scan_a_node()
89 dbg_ntype(ch->node_type), lnum, offs); in ubifs_scan_a_node()
91 if (ubifs_check_node(c, buf, lnum, offs, quiet, 1)) in ubifs_scan_a_node()
101 offs + node_len + pad_len > c->leb_size) { in ubifs_scan_a_node()
104 lnum, offs); in ubifs_scan_a_node()
114 offs, offs + node_len + pad_len); in ubifs_scan_a_node()
119 lnum, offs, ALIGN(offs + node_len + pad_len, 8)); in ubifs_scan_a_node()
138 int offs, void *sbuf) in ubifs_start_scan() argument
143 dbg_scan("scan LEB %d:%d", lnum, offs); in ubifs_start_scan()
[all …]
Dio.c99 int ubifs_leb_read(const struct ubifs_info *c, int lnum, void *buf, int offs, in ubifs_leb_read() argument
104 err = ubi_read(c->ubi, lnum, buf, offs, len); in ubifs_leb_read()
111 len, lnum, offs, err); in ubifs_leb_read()
117 int ubifs_leb_write(struct ubifs_info *c, int lnum, const void *buf, int offs, in ubifs_leb_write() argument
126 err = ubi_leb_write(c->ubi, lnum, buf, offs, len); in ubifs_leb_write()
128 err = dbg_leb_write(c, lnum, buf, offs, len); in ubifs_leb_write()
131 len, lnum, offs, err); in ubifs_leb_write()
238 int offs, int quiet, int must_chk_crc) in ubifs_check_node() argument
244 ubifs_assert(lnum >= 0 && lnum < c->leb_cnt && offs >= 0); in ubifs_check_node()
245 ubifs_assert(!(offs & 7) && offs < c->leb_size); in ubifs_check_node()
[all …]
Drecovery.c113 int err, offs, len; in get_master_node() local
125 offs = 0; in get_master_node()
128 while (offs + UBIFS_MST_NODE_SZ <= c->leb_size) { in get_master_node()
133 offs += sz; in get_master_node()
138 if (offs) { in get_master_node()
141 offs -= sz; in get_master_node()
144 ret = ubifs_scan_a_node(c, buf, len, lnum, offs, 1); in get_master_node()
145 if (ret != SCANNED_A_NODE && offs) { in get_master_node()
147 offs -= sz; in get_master_node()
150 ret = ubifs_scan_a_node(c, buf, len, lnum, offs, 1); in get_master_node()
[all …]
Dlpt_commit.c194 int lnum, offs, len, alen, done_lsave, done_ltab, err; in layout_cnodes() local
204 offs = c->nhead_offs; in layout_cnodes()
208 if (!done_lsave && offs + c->lsave_sz <= c->leb_size) { in layout_cnodes()
211 c->lsave_offs = offs; in layout_cnodes()
212 offs += c->lsave_sz; in layout_cnodes()
216 if (offs + c->ltab_sz <= c->leb_size) { in layout_cnodes()
219 c->ltab_offs = offs; in layout_cnodes()
220 offs += c->ltab_sz; in layout_cnodes()
232 while (offs + len > c->leb_size) { in layout_cnodes()
233 alen = ALIGN(offs, c->min_io_size); in layout_cnodes()
[all …]
Dreplay.c57 int offs; member
224 r->lnum, r->offs, r->len, r->deletion, r->sqnum); in apply_replay_entry()
233 err = ubifs_tnc_add_nm(c, &r->key, r->lnum, r->offs, in apply_replay_entry()
253 err = ubifs_tnc_add(c, &r->key, r->lnum, r->offs, in apply_replay_entry()
356 static int insert_node(struct ubifs_info *c, int lnum, int offs, int len, in insert_node() argument
363 dbg_mntk(key, "add LEB %d:%d, key ", lnum, offs); in insert_node()
375 r->offs = offs; in insert_node()
404 static int insert_dent(struct ubifs_info *c, int lnum, int offs, int len, in insert_dent() argument
411 dbg_mntk(key, "add LEB %d:%d, key ", lnum, offs); in insert_dent()
428 r->offs = offs; in insert_dent()
[all …]
Dtnc.c38 int len, int lnum, int offs);
82 static int insert_old_idx(struct ubifs_info *c, int lnum, int offs) in insert_old_idx() argument
91 old_idx->offs = offs; in insert_old_idx()
101 else if (offs < o->offs) in insert_old_idx()
103 else if (offs > o->offs) in insert_old_idx()
130 return insert_old_idx(c, zbr->lnum, zbr->offs); in insert_old_idx_znode()
134 c->zroot.offs); in insert_old_idx_znode()
155 err = insert_old_idx(c, zbr->lnum, zbr->offs); in ins_clr_old_idx_znode()
159 zbr->offs = 0; in ins_clr_old_idx_znode()
164 err = insert_old_idx(c, c->zroot.lnum, c->zroot.offs); in ins_clr_old_idx_znode()
[all …]
Dlog.c176 int ubifs_add_bud_to_log(struct ubifs_info *c, int jhead, int lnum, int offs) in ubifs_add_bud_to_log() argument
216 if (c->bud_bytes + c->leb_size - offs > c->max_bud_bytes) { in ubifs_add_bud_to_log()
237 bud->start = offs; in ubifs_add_bud_to_log()
242 ref->offs = cpu_to_le32(bud->start); in ubifs_add_bud_to_log()
322 c->cmt_bud_bytes += wbuf->offs - bud->start; in remove_buds()
325 wbuf->offs - bud->start, c->cmt_bud_bytes); in remove_buds()
326 bud->start = wbuf->offs; in remove_buds()
390 int offs = c->jheads[i].wbuf.offs; in ubifs_log_start_commit() local
392 if (lnum == -1 || offs == c->leb_size) in ubifs_log_start_commit()
396 lnum, offs, dbg_jhead(i)); in ubifs_log_start_commit()
[all …]
Dtnc_commit.c38 struct ubifs_znode *znode, int lnum, int offs, int len) in make_idx_node() argument
53 br->offs = cpu_to_le32(zbr->offs); in make_idx_node()
65 znode->offs = offs; in make_idx_node()
77 zbr->offs = offs; in make_idx_node()
81 c->zroot.offs = offs; in make_idx_node()
168 static int find_old_idx(struct ubifs_info *c, int lnum, int offs) in find_old_idx() argument
180 else if (offs < o->offs) in find_old_idx()
182 else if (offs > o->offs) in find_old_idx()
204 int level, int lnum, int offs) in is_idx_node_in_use() argument
208 ret = is_idx_node_in_tnc(c, key, level, lnum, offs); in is_idx_node_in_use()
[all …]
Djournal.c117 int err = 0, err1, retries = 0, avail, lnum, offs, squeeze; in reserve_space() local
135 avail = c->leb_size - wbuf->offs - wbuf->used; in reserve_space()
143 lnum = ubifs_find_free_space(c, len, &offs, squeeze); in reserve_space()
184 avail = c->leb_size - wbuf->offs - wbuf->used; in reserve_space()
193 lnum, wbuf->lnum, wbuf->offs + wbuf->used); in reserve_space()
200 offs = 0; in reserve_space()
214 err = ubifs_add_bud_to_log(c, jhead, lnum, offs); in reserve_space()
217 err = ubifs_wbuf_seek_nolock(wbuf, lnum, offs); in reserve_space()
256 int *lnum, int *offs) in write_node() argument
263 *offs = c->jheads[jhead].wbuf.offs + c->jheads[jhead].wbuf.used; in write_node()
[all …]
Dmaster.c40 int lnum, offs = 0, nodes_cnt; in scan_for_master() local
54 offs = snod->offs; in scan_for_master()
70 if (snod->offs != offs) in scan_for_master()
76 c->mst_offs = offs; in scan_for_master()
86 snod->type, lnum, snod->offs); in scan_for_master()
127 c->zroot.offs >= c->leb_size || c->zroot.offs & 7) { in validate_master()
283 c->zroot.offs = le32_to_cpu(c->mst_node->root_offs); in ubifs_read_master()
361 int err, lnum, offs, len; in ubifs_write_master() local
368 offs = c->mst_offs + c->mst_node_alsz; in ubifs_write_master()
371 if (offs + UBIFS_MST_NODE_SZ > c->leb_size) { in ubifs_write_master()
[all …]
Dubifs.h263 int offs; member
289 int offs; member
571 int offs; member
671 int offs; member
733 int offs; member
765 int offs; member
1462 int ubifs_leb_read(const struct ubifs_info *c, int lnum, void *buf, int offs,
1464 int ubifs_leb_write(struct ubifs_info *c, int lnum, const void *buf, int offs,
1471 int ubifs_wbuf_seek_nolock(struct ubifs_wbuf *wbuf, int lnum, int offs);
1474 int lnum, int offs);
[all …]
Dtnc_misc.c273 static int read_znode(struct ubifs_info *c, int lnum, int offs, int len, in read_znode() argument
283 err = ubifs_read_node(c, idx, UBIFS_IDX_NODE, len, lnum, offs); in read_znode()
293 lnum, offs, znode->level, znode->child_cnt); in read_znode()
310 zbr->offs = le32_to_cpu(br->offs); in read_znode()
317 zbr->lnum >= c->leb_cnt || zbr->offs < 0 || in read_znode()
318 zbr->offs + zbr->len > c->leb_size || zbr->offs & 7) { in read_znode()
389 ubifs_err(c, "bad indexing node at LEB %d:%d, error %d", lnum, offs, err); in read_znode()
422 err = read_znode(c, zbr->lnum, zbr->offs, zbr->len, znode); in ubifs_load_znode()
472 zbr->lnum, zbr->offs); in ubifs_tnc_read_node()
475 zbr->offs); in ubifs_tnc_read_node()
[all …]
Dcommit.c176 c->mst_node->root_offs = cpu_to_le32(zroot.offs); in do_commit()
529 int lnum, offs, len, err = 0; in dbg_old_index_check_init() local
534 offs = d->old_zroot.offs; in dbg_old_index_check_init()
541 err = ubifs_read_node(c, idx, UBIFS_IDX_NODE, len, lnum, offs); in dbg_old_index_check_init()
567 int lnum, offs, len, err = 0, uninitialized_var(last_level), child_cnt; in dbg_check_old_index() local
587 offs = d->old_zroot.offs; in dbg_check_old_index()
609 err = ubifs_read_node(c, idx, UBIFS_IDX_NODE, len, lnum, offs); in dbg_check_old_index()
698 offs = le32_to_cpu(br->offs); in dbg_check_old_index()
Dgc.c88 wbuf->lnum, wbuf->offs + wbuf->used, gc_lnum, in switch_gc_head()
89 c->leb_size - wbuf->offs - wbuf->used); in switch_gc_head()
275 snod->offs, 0); in sort_nodes()
320 int err, new_lnum = wbuf->lnum, new_offs = wbuf->offs + wbuf->used; in move_node()
328 snod->offs, new_lnum, new_offs, in move_node()
372 avail = c->leb_size - wbuf->offs - wbuf->used; in move_nodes()
387 avail = c->leb_size - wbuf->offs - wbuf->used; in move_nodes()
472 ubifs_assert(c->gc_lnum != -1 || wbuf->offs + wbuf->used == 0 || in ubifs_garbage_collect_leb()
531 snod->offs); in ubifs_garbage_collect_leb()
716 space_before = c->leb_size - wbuf->offs - wbuf->used; in ubifs_garbage_collect()
[all …]
Dlpt.c399 pack_bits(&addr, &pos, nnode->nbranch[i].offs, in ubifs_pack_nnode()
753 nnode->nbranch[j].offs = boffs; in ubifs_create_dflt_lpt()
758 nnode->nbranch[j].offs = 0; in ubifs_create_dflt_lpt()
1020 nnode->nbranch[i].offs = ubifs_unpack_bits(&addr, &pos, in ubifs_unpack_nnode()
1114 int offs = nnode->nbranch[i].offs; in validate_nnode() local
1117 if (offs != 0) in validate_nnode()
1123 if (offs < 0 || offs > max_offs) in validate_nnode()
1198 int err, lnum, offs; in ubifs_read_nnode() local
1203 offs = branch->offs; in ubifs_read_nnode()
1206 offs = c->lpt_offs; in ubifs_read_nnode()
[all …]
Ddebug.c411 pr_err("\toffs %u\n", le32_to_cpu(ref->offs)); in ubifs_dump_node()
516 i, le32_to_cpu(br->lnum), le32_to_cpu(br->offs), in ubifs_dump_node()
797 const struct ubifs_scan_leb *sleb, int offs) in ubifs_dump_sleb() argument
802 current->pid, sleb->lnum, offs); in ubifs_dump_sleb()
807 sleb->lnum, snod->offs, snod->len); in ubifs_dump_sleb()
838 snod->offs, snod->len); in ubifs_dump_leb()
864 znode, zbr->lnum, zbr->offs, zbr->len, znode->parent, znode->iip, in ubifs_dump_znode()
877 n, zbr->znode, zbr->lnum, zbr->offs, zbr->len, in ubifs_dump_znode()
882 n, zbr->znode, zbr->lnum, zbr->offs, zbr->len, in ubifs_dump_znode()
1211 zbr1->offs, dbg_snprintf_key(c, &key, key_buf, in dbg_check_key_order()
[all …]
Dfind.c493 int ubifs_find_free_space(struct ubifs_info *c, int min_space, int *offs, in ubifs_find_free_space() argument
561 *offs = c->leb_size - lprops->free; in ubifs_find_free_space()
564 if (*offs == 0) { in ubifs_find_free_space()
576 dbg_find("found LEB %d, free %d", lnum, c->leb_size - *offs); in ubifs_find_free_space()
577 ubifs_assert(*offs <= c->leb_size - min_space); in ubifs_find_free_space()
/fs/crypto/
Dcrypto.c139 unsigned int offs, gfp_t gfp_flags) in fscrypt_do_page_crypto() argument
177 sg_set_page(&dst, dest_page, len, offs); in fscrypt_do_page_crypto()
179 sg_set_page(&src, src_page, len, offs); in fscrypt_do_page_crypto()
239 unsigned int offs, in fscrypt_encrypt_page() argument
252 ciphertext_page, len, offs, in fscrypt_encrypt_page()
273 page, ciphertext_page, len, offs, in fscrypt_encrypt_page()
306 unsigned int len, unsigned int offs, u64 lblk_num) in fscrypt_decrypt_page() argument
312 len, offs, GFP_NOFS); in fscrypt_decrypt_page()
/fs/nilfs2/
Ddir.c131 unsigned int offs, rec_len; in nilfs_check_page() local
143 for (offs = 0; offs <= limit - NILFS_DIR_REC_LEN(1); offs += rec_len) { in nilfs_check_page()
144 p = (struct nilfs_dir_entry *)(kaddr + offs); in nilfs_check_page()
153 if (((offs + rec_len - 1) ^ offs) & ~(chunk_size-1)) in nilfs_check_page()
156 if (offs != limit) in nilfs_check_page()
183 dir->i_ino, error, (page->index << PAGE_SHIFT) + offs, in nilfs_check_page()
188 p = (struct nilfs_dir_entry *)(kaddr + offs); in nilfs_check_page()
191 dir->i_ino, (page->index << PAGE_SHIFT) + offs, in nilfs_check_page()
/fs/exofs/
Ddir.c87 unsigned offs, rec_len; in exofs_check_page() local
100 for (offs = 0; offs <= limit - EXOFS_DIR_REC_LEN(1); offs += rec_len) { in exofs_check_page()
101 p = (struct exofs_dir_entry *)(kaddr + offs); in exofs_check_page()
110 if (((offs + rec_len - 1) ^ offs) & ~(chunk_size-1)) in exofs_check_page()
113 if (offs != limit) in exofs_check_page()
141 dir->i_ino, error, (page->index<<PAGE_SHIFT)+offs, in exofs_check_page()
146 p = (struct exofs_dir_entry *)(kaddr + offs); in exofs_check_page()
150 dir->i_ino, (page->index<<PAGE_SHIFT)+offs, in exofs_check_page()
/fs/ext2/
Ddir.c120 unsigned offs, rec_len; in ext2_check_page() local
132 for (offs = 0; offs <= limit - EXT2_DIR_REC_LEN(1); offs += rec_len) { in ext2_check_page()
133 p = (ext2_dirent *)(kaddr + offs); in ext2_check_page()
142 if (unlikely(((offs + rec_len - 1) ^ offs) & ~(chunk_size-1))) in ext2_check_page()
147 if (offs != limit) in ext2_check_page()
179 dir->i_ino, error, (page->index<<PAGE_SHIFT)+offs, in ext2_check_page()
185 p = (ext2_dirent *)(kaddr + offs); in ext2_check_page()
189 dir->i_ino, (page->index<<PAGE_SHIFT)+offs, in ext2_check_page()
Dxattr.c420 size_t offs = le16_to_cpu(here->e_value_offs); in ext2_xattr_set() local
421 if (offs < min_offs) in ext2_xattr_set()
422 min_offs = offs; in ext2_xattr_set()
440 size_t offs = le16_to_cpu(last->e_value_offs); in ext2_xattr_set() local
441 if (offs < min_offs) in ext2_xattr_set()
442 min_offs = offs; in ext2_xattr_set()
543 size_t offs = le16_to_cpu(here->e_value_offs); in ext2_xattr_set() local
544 char *val = (char *)header + offs; in ext2_xattr_set()
568 if (!last->e_value_block && o < offs) in ext2_xattr_set()
/fs/ufs/
Ddir.c113 unsigned offs, rec_len; in ufs_check_page() local
126 for (offs = 0; offs <= limit - UFS_DIR_REC_LEN(1); offs += rec_len) { in ufs_check_page()
127 p = (struct ufs_dir_entry *)(kaddr + offs); in ufs_check_page()
136 if (((offs + rec_len - 1) ^ offs) & ~chunk_mask) in ufs_check_page()
142 if (offs != limit) in ufs_check_page()
173 dir->i_ino, error, (page->index<<PAGE_SHIFT)+offs, in ufs_check_page()
177 p = (struct ufs_dir_entry *)(kaddr + offs); in ufs_check_page()
181 dir->i_ino, (page->index<<PAGE_SHIFT)+offs); in ufs_check_page()
/fs/jffs2/
Ddebug.h214 __jffs2_dbg_dump_buffer(unsigned char *buf, int len, uint32_t offs);
250 #define jffs2_dbg_dump_buffer(buf, len, offs) \ argument
251 __jffs2_dbg_dump_buffer(*buf, len, offs);
261 #define jffs2_dbg_dump_buffer(buf, len, offs) argument
Ddebug.c737 __jffs2_dbg_dump_buffer(unsigned char *buf, int len, uint32_t offs) in __jffs2_dbg_dump_buffer() argument
743 offs, offs + len, len); in __jffs2_dbg_dump_buffer()
744 i = skip = offs % JFFS2_BUFDUMP_BYTES_PER_LINE; in __jffs2_dbg_dump_buffer()
745 offs = offs & ~(JFFS2_BUFDUMP_BYTES_PER_LINE - 1); in __jffs2_dbg_dump_buffer()
748 printk(JFFS2_DBG "%#08x: ", offs); in __jffs2_dbg_dump_buffer()
757 offs += JFFS2_BUFDUMP_BYTES_PER_LINE; in __jffs2_dbg_dump_buffer()
758 printk(JFFS2_DBG "%0#8x: ", offs); in __jffs2_dbg_dump_buffer()

12