/external/e2fsprogs/lib/ext2fs/ |
D | icount.c | 45 ext2_ino_t ino; member 265 icount->list[i].ino = hint->list[i].ino; in ext2fs_create_icount2() 289 ext2_ino_t ino, int pos) in insert_icount_el() argument 296 if (icount->last_lookup && icount->last_lookup->ino == ino) in insert_icount_el() 301 new_size = icount->list[(unsigned)icount->count-1].ino; in insert_icount_el() 329 el->ino = ino; in insert_icount_el() 340 ext2_ino_t ino, int create) in get_icount_el() argument 350 (ino > icount->list[(unsigned)icount->count-1].ino))) { in get_icount_el() 351 return insert_icount_el(icount, ino, (unsigned) icount->count); in get_icount_el() 358 if (ino == icount->list[icount->cursor].ino) in get_icount_el() [all …]
|
D | inode.c | 68 fs->icache->cache[i].ino = 0; in ext2fs_flush_icache() 111 errcode_t (*save_get_blocks)(ext2_filsys f, ext2_ino_t ino, blk_t *blocks); in ext2fs_open_inode_scan() 404 errcode_t ext2fs_get_next_inode_full(ext2_inode_scan scan, ext2_ino_t *ino, in ext2fs_get_next_inode_full() argument 425 *ino = 0; in ext2fs_get_next_inode_full() 508 *ino = scan->current_inode; in ext2fs_get_next_inode_full() 512 errcode_t ext2fs_get_next_inode(ext2_inode_scan scan, ext2_ino_t *ino, in ext2fs_get_next_inode() argument 515 return ext2fs_get_next_inode_full(scan, ino, inode, in ext2fs_get_next_inode() 522 errcode_t ext2fs_read_inode_full(ext2_filsys fs, ext2_ino_t ino, in ext2fs_read_inode_full() argument 535 retval = (fs->read_inode)(fs, ino, inode); in ext2fs_read_inode_full() 539 if ((ino == 0) || (ino > fs->super->s_inodes_count)) in ext2fs_read_inode_full() [all …]
|
D | alloc_stats.c | 17 void ext2fs_inode_alloc_stats2(ext2_filsys fs, ext2_ino_t ino, in ext2fs_inode_alloc_stats2() argument 20 int group = ext2fs_group_of_ino(fs, ino); in ext2fs_inode_alloc_stats2() 23 if (ino > fs->super->s_inodes_count) { in ext2fs_inode_alloc_stats2() 25 "Illegal inode number: %lu", (unsigned long) ino); in ext2fs_inode_alloc_stats2() 30 ext2fs_mark_inode_bitmap(fs->inode_map, ino); in ext2fs_inode_alloc_stats2() 32 ext2fs_unmark_inode_bitmap(fs->inode_map, ino); in ext2fs_inode_alloc_stats2() 46 if (ino >= first_unused_inode) in ext2fs_inode_alloc_stats2() 49 fs->super->s_inodes_per_group - ino; in ext2fs_inode_alloc_stats2() 58 void ext2fs_inode_alloc_stats(ext2_filsys fs, ext2_ino_t ino, int inuse) in ext2fs_inode_alloc_stats() argument 60 ext2fs_inode_alloc_stats2(fs, ino, inuse, 0); in ext2fs_inode_alloc_stats()
|
D | mkdir.c | 38 ext2_ino_t ino = inum; in ext2fs_mkdir() local 48 if (!ino) { in ext2fs_mkdir() 50 0, &ino); in ext2fs_mkdir() 65 retval = ext2fs_new_dir_block(fs, ino, parent, &block); in ext2fs_mkdir() 72 if (parent != ino) { in ext2fs_mkdir() 96 retval = ext2fs_write_new_inode(fs, ino, &inode); in ext2fs_mkdir() 113 retval = ext2fs_link(fs, parent, name, ino, EXT2_FT_DIR); in ext2fs_mkdir() 121 if (parent != ino) { in ext2fs_mkdir() 132 ext2fs_inode_alloc_stats2(fs, ino, +1, 1); in ext2fs_mkdir()
|
D | irel_ma.c | 35 static errcode_t ima_add_ref(ext2_irel irel, ext2_ino_t ino, 37 static errcode_t ima_start_iter_ref(ext2_irel irel, ext2_ino_t ino); 197 ext2_ino_t ino; 202 ino = ma->orig_map[(unsigned) orig]; 203 if (ino == 0) 205 *old = ino; 206 *ent = ma->entries[(unsigned) ino]; 233 static errcode_t ima_add_ref(ext2_irel irel, ext2_ino_t ino, 243 if (ino > ma->max_inode) 246 ref_ent = ma->ref_entries + (unsigned) ino; [all …]
|
D | bmove.c | 29 ext2_ino_t ino; member 80 printf("ino=%ld, blockcnt=%lld, %u->%u\n", pb->ino, in process_block() 84 retval = ext2fs_add_dir_block(fs->dblist, pb->ino, in process_block() 99 ext2_ino_t ino; in ext2fs_move_blocks() local 135 retval = ext2fs_get_next_inode(scan, &ino, &inode); in ext2fs_move_blocks() 139 while (ino) { in ext2fs_move_blocks() 144 pb.ino = ino; in ext2fs_move_blocks() 150 retval = ext2fs_block_iterate2(fs, ino, 0, block_buf, in ext2fs_move_blocks() 158 retval = ext2fs_get_next_inode(scan, &ino, &inode); in ext2fs_move_blocks()
|
D | get_pathname.c | 72 ext2_ino_t ino, int maxdepth, in ext2fs_get_pathname_int() argument 79 if (dir == ino) { in ext2fs_get_pathname_int() 95 gp.search_ino = ino; in ext2fs_get_pathname_int() 112 if (!ino) { in ext2fs_get_pathname_int() 143 errcode_t ext2fs_get_pathname(ext2_filsys fs, ext2_ino_t dir, ext2_ino_t ino, in ext2fs_get_pathname() argument 154 if (dir == ino) in ext2fs_get_pathname() 155 ino = 0; in ext2fs_get_pathname() 156 retval = ext2fs_get_pathname_int(fs, dir, ino, 32, buf, name); in ext2fs_get_pathname()
|
D | ext2fs.h | 137 ext2_ino_t ino; member 213 errcode_t (*get_blocks)(ext2_filsys fs, ext2_ino_t ino, blk_t *blocks); 214 errcode_t (*check_directory)(ext2_filsys fs, ext2_ino_t ino); 216 errcode_t (*read_inode)(ext2_filsys fs, ext2_ino_t ino, 218 errcode_t (*write_inode)(ext2_filsys fs, ext2_ino_t ino, 594 void ext2fs_inode_alloc_stats(ext2_filsys fs, ext2_ino_t ino, int inuse); 595 void ext2fs_inode_alloc_stats2(ext2_filsys fs, ext2_ino_t ino, 697 ext2_ino_t ino, 706 ext2_ino_t ino, 718 extern errcode_t ext2fs_bmap(ext2_filsys fs, ext2_ino_t ino, [all …]
|
/external/e2fsprogs/e2fsck/ |
D | dx_dirinfo.c | 16 void e2fsck_add_dx_dir(e2fsck_t ctx, ext2_ino_t ino, int num_blocks) in e2fsck_add_dx_dir() argument 24 printf("add_dx_dir_info for inode %lu...\n", ino); in e2fsck_add_dx_dir() 57 ctx->dx_dir_info[ctx->dx_dir_info_count-1].ino >= ino) { in e2fsck_add_dx_dir() 59 if (ctx->dx_dir_info[i-1].ino < ino) in e2fsck_add_dx_dir() 62 if (dir->ino != ino) in e2fsck_add_dx_dir() 68 dir->ino = ino; in e2fsck_add_dx_dir() 81 struct dx_dir_info *e2fsck_get_dx_dir_info(e2fsck_t ctx, ext2_ino_t ino) in e2fsck_get_dx_dir_info() argument 89 if (ino == ctx->dx_dir_info[low].ino) in e2fsck_get_dx_dir_info() 91 if (ino == ctx->dx_dir_info[high].ino) in e2fsck_get_dx_dir_info() 98 if (ino == ctx->dx_dir_info[mid].ino) in e2fsck_get_dx_dir_info() [all …]
|
D | dirinfo.c | 109 void e2fsck_add_dir_info(e2fsck_t ctx, ext2_ino_t ino, ext2_ino_t parent) in e2fsck_add_dir_info() argument 118 printf("add_dir_info for inode (%lu, %lu)...\n", ino, parent); in e2fsck_add_dir_info() 136 ent.ino = ino; in e2fsck_add_dir_info() 155 ctx->dir_info->array[ctx->dir_info->count-1].ino >= ino) { in e2fsck_add_dir_info() 157 if (ctx->dir_info->array[i-1].ino < ino) in e2fsck_add_dir_info() 160 if (dir->ino != ino) in e2fsck_add_dir_info() 166 dir->ino = ino; in e2fsck_add_dir_info() 175 static struct dir_info *e2fsck_get_dir_info(e2fsck_t ctx, ext2_ino_t ino) in e2fsck_get_dir_info() argument 186 printf("e2fsck_get_dir_info %d...", ino); in e2fsck_get_dir_info() 192 key.dptr = (unsigned char *) &ino; in e2fsck_get_dir_info() [all …]
|
D | pass3.c | 45 static int check_directory(e2fsck_t ctx, ext2_ino_t ino, 47 static void fix_dotdot(e2fsck_t ctx, ext2_ino_t ino, ext2_ino_t parent); 105 if (ext2fs_test_inode_bitmap(ctx->inode_dir_map, dir->ino)) in e2fsck_pass3() 106 if (check_directory(ctx, dir->ino, &pctx)) in e2fsck_pass3() 263 ext2_ino_t ino = dir, parent; in check_directory() local 277 if (ext2fs_mark_inode_bitmap(inode_done_map, ino)) in check_directory() 280 if (e2fsck_dir_info_get_parent(ctx, ino, &parent)) { in check_directory() 294 pctx->ino = ino; in check_directory() 296 if (e2fsck_reconnect_file(ctx, pctx->ino)) in check_directory() 299 fix_dotdot(ctx, pctx->ino, in check_directory() [all …]
|
D | pass1b.c | 88 static void delete_file(e2fsck_t ctx, ext2_ino_t ino, 90 static int clone_file(e2fsck_t ctx, ext2_ino_t ino, 118 static void add_dupe(e2fsck_t ctx, ext2_ino_t ino, blk_t blk, in add_dupe() argument 139 ino_el->inode = ino; in add_dupe() 144 n = dict_lookup(&ino_dict, INT_TO_VOIDPTR(ino)); in add_dupe() 150 if (ino == EXT2_ROOT_INO) { in add_dupe() 159 dict_alloc_insert(&ino_dict, INT_TO_VOIDPTR(ino), di); in add_dupe() 258 ext2_ino_t ino; member 267 ext2_ino_t ino; in pass1b() local 289 pctx.errcode = ext2fs_get_next_inode(scan, &ino, &inode); in pass1b() [all …]
|
D | pass1.c | 69 static void mark_inode_bad(e2fsck_t ctx, ino_t ino); 80 ext2_ino_t ino; member 96 ext2_ino_t ino; member 167 int e2fsck_pass1_check_symlink(ext2_filsys fs, ext2_ino_t ino, in e2fsck_pass1_check_symlink() argument 184 if (ext2fs_extent_open2(fs, ino, inode, &handle)) in e2fsck_pass1_check_symlink() 248 e2fsck_write_inode(ctx, pctx->ino, pctx->inode, "pass1"); in check_immutable() 267 e2fsck_write_inode(ctx, pctx->ino, pctx->inode, "pass1"); in check_size() 346 e2fsck_write_inode_full(ctx, pctx->ino, pctx->inode, in check_ea_in_inode() 364 printf("inode #%u, i_extra_size %d\n", pctx->ino, in check_inode_extra_space() 379 e2fsck_write_inode_full(ctx, pctx->ino, pctx->inode, in check_inode_extra_space() [all …]
|
D | emptydir.c | 26 ext2_ino_t ino; member 94 if (db->ino == 11) in add_empty_dirblock() 98 db->blk, db->blockcnt, db->ino); in add_empty_dirblock() 101 if (ext2fs_test_inode_bitmap(edi->dir_map, db->ino)) in add_empty_dirblock() 103 ext2fs_mark_inode_bitmap(edi->dir_map, db->ino); in add_empty_dirblock() 105 ext2fs_add_dir_block(edi->empty_dblist, db->ino, in add_empty_dirblock() 130 retval = ext2fs_bmap(fs, edi->ino, &edi->inode, in empty_pass1() 158 edi->ino = db->ino; in fix_directory() 160 retval = ext2fs_read_inode(fs, db->ino, &edi->inode); in fix_directory() 164 retval = ext2fs_block_iterate2(fs, db->ino, 0, edi->block_buf, in fix_directory() [all …]
|
D | pass2.c | 62 static void deallocate_inode(e2fsck_t ctx, ext2_ino_t ino, char* block_buf); 69 static void clear_htree(e2fsck_t ctx, ext2_ino_t ino); 167 pctx.dir = dx_dir->ino; in e2fsck_pass2() 242 clear_htree(ctx, dx_dir->ino); in e2fsck_pass2() 331 if (db_a->ino != db_b->ino) in special_dir_block_cmp() 332 return (int) (db_a->ino - db_b->ino); in special_dir_block_cmp() 344 ext2_ino_t ino, struct problem_context *pctx) in check_dot() argument 365 dirent->inode = ino; in check_dot() 373 if (dirent->inode != ino) { in check_dot() 375 dirent->inode = ino; in check_dot() [all …]
|
D | e2fsck.h | 88 ext2_ino_t ino; /* Inode number */ member 99 ext2_ino_t ino; /* Inode number */ member 393 extern void e2fsck_add_dir_info(e2fsck_t ctx, ext2_ino_t ino, ext2_ino_t parent); 400 extern int e2fsck_dir_info_set_parent(e2fsck_t ctx, ext2_ino_t ino, 402 extern int e2fsck_dir_info_set_dotdot(e2fsck_t ctx, ext2_ino_t ino, 404 extern int e2fsck_dir_info_get_parent(e2fsck_t ctx, ext2_ino_t ino, 406 extern int e2fsck_dir_info_get_dotdot(e2fsck_t ctx, ext2_ino_t ino, 410 extern void e2fsck_add_dx_dir(e2fsck_t ctx, ext2_ino_t ino, int num_blocks); 411 extern struct dx_dir_info *e2fsck_get_dx_dir_info(e2fsck_t ctx, ext2_ino_t ino); 447 extern int e2fsck_pass1_check_symlink(ext2_filsys fs, ext2_ino_t ino, [all …]
|
D | rehash.c | 69 ino_t ino; member 152 ent->ino = dirent->inode; in fill_dir_block() 174 return (he_a->ino - he_b->ino); in ino_cmp() 331 ext2_ino_t ino, in duplicate_search_and_fix() argument 343 pctx.ino = ino; in duplicate_search_and_fix() 490 ext2_ino_t ino, ext2_ino_t parent) in set_root_node() argument 502 dir->inode = ino; in set_root_node() 551 ext2_ino_t ino, in calculate_tree() argument 562 root_info = set_root_node(fs, outdir->buf, ino, parent); in calculate_tree() 668 ext2_ino_t ino, int compress) in write_directory() argument [all …]
|
/external/e2fsprogs/debugfs/ |
D | util.c | 109 ext2_ino_t ino; in string_to_inode() local 119 ino = strtoul(str+1, &end, 0); in string_to_inode() 121 return ino; in string_to_inode() 124 retval = ext2fs_namei(current_fs, root, cwd, str, &ino); in string_to_inode() 129 return ino; in string_to_inode() 354 int debugfs_read_inode_full(ext2_ino_t ino, struct ext2_inode * inode, in debugfs_read_inode_full() argument 359 retval = ext2fs_read_inode_full(current_fs, ino, inode, bufsize); in debugfs_read_inode_full() 361 com_err(cmd, retval, "while reading inode %u", ino); in debugfs_read_inode_full() 367 int debugfs_read_inode(ext2_ino_t ino, struct ext2_inode * inode, in debugfs_read_inode() argument 372 retval = ext2fs_read_inode(current_fs, ino, inode); in debugfs_read_inode() [all …]
|
D | icheck.c | 23 ext2_ino_t ino; member 44 if (!bw->barray[i].ino && bw->barray[i].blk == *block_nr) { in icheck_proc() 45 bw->barray[i].ino = bw->inode; in icheck_proc() 61 ext2_ino_t ino; in do_icheck() local 101 retval = ext2fs_get_next_inode(scan, &ino, &inode); in do_icheck() 108 while (ino) { in do_icheck() 112 bw.inode = ino; in do_icheck() 130 retval = ext2fs_block_iterate2(current_fs, ino, in do_icheck() 144 retval = ext2fs_get_next_inode(scan, &ino, &inode); in do_icheck() 155 if (binfo->ino == 0) { in do_icheck() [all …]
|
D | dump.c | 100 static void dump_file(const char *cmdname, ext2_ino_t ino, int fd, in dump_file() argument 110 if (debugfs_read_inode(ino, &inode, cmdname)) in dump_file() 113 retval = ext2fs_file_open(current_fs, ino, 0, &e2_file); in dump_file() 188 static void rdump_symlink(ext2_ino_t ino, struct ext2_inode *inode, in rdump_symlink() argument 208 retval = ext2fs_file_open(current_fs, ino, 0, &e2_file); in rdump_symlink() 242 static void rdump_inode(ext2_ino_t ino, struct ext2_inode *inode, in rdump_inode() argument 257 rdump_symlink(ino, inode, fullname); in rdump_inode() 265 dump_file("rdump", ino, fd, 1, fullname); in rdump_inode() 278 retval = ext2fs_dir_iterate(current_fs, ino, 0, 0, in rdump_inode() 316 ext2_ino_t ino; in do_rdump() local [all …]
|
D | lsdel.c | 24 ext2_ino_t ino; member 79 ext2_ino_t ino; in do_lsdel() local 125 retval = ext2fs_get_next_inode(scan, &ino, &inode); in do_lsdel() 133 while (ino) { in do_lsdel() 138 lsd.inode = ino; in do_lsdel() 143 retval = ext2fs_block_iterate2(current_fs, ino, in do_lsdel() 164 delarray[num_delarray].ino = ino; in do_lsdel() 179 retval = ext2fs_get_next_inode(scan, &ino, &inode); in do_lsdel() 197 delarray[i].ino, in do_lsdel()
|
D | ls.c | 53 ext2_ino_t ino; in list_dir_proc() local 67 ino = dirent->inode; in list_dir_proc() 72 ino = 0; in list_dir_proc() 77 if (ino && debugfs_read_inode(ino, &inode, name)) return 0; in list_dir_proc() 78 fprintf(ls->f,"/%u/%06o/%d/%d/%s/",ino,inode.i_mode,inode.i_uid, inode.i_gid,name); in list_dir_proc() 86 if (ino) { in list_dir_proc() 87 if (debugfs_read_inode(ino, &inode, name)) in list_dir_proc() 99 fprintf(ls->f, "%c%6u%c %6o (%d) %5d %5d ", lbr, ino, rbr, in list_dir_proc()
|
D | htree.c | 31 static void htree_dump_leaf_node(ext2_filsys fs, ext2_ino_t ino, in htree_dump_leaf_node() argument 47 errcode = ext2fs_bmap(fs, ino, inode, buf, 0, blk, &pblk); in htree_dump_leaf_node() 109 static void htree_dump_int_block(ext2_filsys fs, ext2_ino_t ino, 115 static void htree_dump_int_node(ext2_filsys fs, ext2_ino_t ino, in htree_dump_int_node() argument 148 htree_dump_int_block(fs, ino, inode, rootnode, in htree_dump_int_node() 151 htree_dump_leaf_node(fs, ino, inode, rootnode, in htree_dump_int_node() 158 static void htree_dump_int_block(ext2_filsys fs, ext2_ino_t ino, in htree_dump_int_block() argument 173 errcode = ext2fs_bmap(fs, ino, inode, buf, 0, blk, &pblk); in htree_dump_int_block() 187 htree_dump_int_node(fs, ino, inode, rootnode, in htree_dump_int_block() 198 ext2_ino_t ino; in do_htree_dump() local [all …]
|
/external/e2fsprogs/tests/progs/ |
D | test_icount.c | 51 const char *str, ext2_ino_t *ino) in parse_inode() argument 55 *ino = strtoul(str, &tmp, 0); in parse_inode() 106 ext2_ino_t ino; in do_fetch() local 115 if (parse_inode(argv[0], "inode", argv[1], &ino)) in do_fetch() 117 retval = ext2fs_icount_fetch(test_icount, ino, &count); in do_fetch() 129 ext2_ino_t ino; in do_increment() local 138 if (parse_inode(argv[0], "inode", argv[1], &ino)) in do_increment() 140 retval = ext2fs_icount_increment(test_icount, ino, &count); in do_increment() 153 ext2_ino_t ino; in do_decrement() local 162 if (parse_inode(argv[0], "inode", argv[1], &ino)) in do_decrement() [all …]
|
/external/grub/stage2/ |
D | fsys_xfs.c | 83 ino2agno (xfs_ino_t ino) in ino2agno() argument 85 return ino >> XFS_INO_AGINO_BITS; in ino2agno() 89 ino2agino (xfs_ino_t ino) in ino2agino() argument 91 return ino & XFS_INO_MASK(XFS_INO_AGINO_BITS); in ino2agino() 95 ino2offset (xfs_ino_t ino) in ino2offset() argument 97 return ino & XFS_INO_MASK(XFS_INO_OFFSET_BITS); in ino2offset() 202 di_read (xfs_ino_t ino) in di_read() argument 210 agno = ino2agno (ino); in di_read() 211 agino = ino2agino (ino); in di_read() 213 offset = ino2offset (ino); in di_read() [all …]
|