Lines Matching full:current_fs
55 ext2_filsys current_fs;
143 current_fs = NULL;
151 current_fs = NULL;
157 current_fs = NULL;
177 io_ptr, ¤t_fs);
182 current_fs = NULL;
185 current_fs->default_bitmap_type = EXT2FS_BMAP64_RBTREE;
190 retval = ext2fs_read_inode_bitmap(current_fs);
195 retval = ext2fs_read_block_bitmap(current_fs);
203 retval = ext2fs_set_data_io(current_fs, data_io);
215 retval = ext2fs_close_free(¤t_fs);
315 if (current_fs->flags & EXT2_FLAG_IB_DIRTY) {
316 retval = ext2fs_write_inode_bitmap(current_fs);
320 if (current_fs->flags & EXT2_FLAG_BB_DIRTY) {
321 retval = ext2fs_write_block_bitmap(current_fs);
327 retval = ext2fs_close_free(¤t_fs);
344 current_fs->flags &= ~EXT2_FLAG_MASTER_SB_ONLY;
378 unix_io_manager, ¤t_fs);
381 current_fs = NULL;
446 if (ext2fs_has_feature_bigalloc(current_fs->super))
449 list_super2(current_fs->super, out);
450 for (i=0; i < current_fs->group_desc_count; i++)
451 numdirs += ext2fs_bg_used_dirs_count(current_fs, i);
459 gdt_csum = ext2fs_has_group_desc_csum(current_fs);
460 for (i = 0; i < current_fs->group_desc_count; i++) {
467 i, ext2fs_block_bitmap_loc(current_fs, i),
468 ext2fs_inode_bitmap_loc(current_fs, i),
469 ext2fs_inode_table_loc(current_fs, i),
470 ext2fs_bg_free_blocks_count(current_fs, i), units,
471 ext2fs_bg_free_blocks_count(current_fs, i) != 1 ?
473 ext2fs_bg_free_inodes_count(current_fs, i),
474 ext2fs_bg_free_inodes_count(current_fs, i) != 1 ?
476 ext2fs_bg_used_dirs_count(current_fs, i),
477 ext2fs_bg_used_dirs_count(current_fs, i) != 1 ? "directories"
481 ext2fs_bg_itable_unused(current_fs, i),
482 ext2fs_bg_itable_unused(current_fs, i) != 1 ?
485 print_bg_opts(current_fs, i, EXT2_BG_INODE_UNINIT, "Inode not init",
487 print_bg_opts(current_fs, i, EXT2_BG_BLOCK_UNINIT, "Block not init",
491 first ? " [":", ", ext2fs_bg_checksum(current_fs, i));
513 current_fs->super->s_state |= EXT2_VALID_FS;
515 current_fs->super->s_state &= ~EXT2_VALID_FS;
516 ext2fs_mark_super_dirty(current_fs);
597 if (inode->i_extra_isize > EXT2_INODE_SIZE(current_fs->super) -
614 ext2fs_block_iterate3(current_fs, inode, BLOCK_FLAG_READ_ONLY, NULL,
648 errcode = ext2fs_extent_open(current_fs, ino, &handle);
759 retval = ext2fs_inline_data_size(current_fs, inode_num, &size);
772 retval = ext2fs_inline_data_size(current_fs, inode_num, &size);
780 retval = ext2fs_inline_data_get(current_fs, inode_num,
809 int os = current_fs->super->s_creator_os;
813 if (EXT2_INODE_SIZE(current_fs->super) > EXT2_GOOD_OLD_INODE_SIZE)
910 if (EXT2_INODE_SIZE(current_fs->super) > EXT2_GOOD_OLD_INODE_SIZE)
914 if (ext2fs_has_feature_metadata_csum(current_fs->super)) {
926 ext2fs_inode_data_blocks(current_fs, inode) == 0)
973 malloc(EXT2_INODE_SIZE(current_fs->super));
985 EXT2_INODE_SIZE(current_fs->super))) {
1041 logical_width = int_log10((EXT2_I_SIZE(&inode)+current_fs->blocksize-1)/
1042 current_fs->blocksize) + 1;
1045 physical_width = int_log10(ext2fs_blocks_count(current_fs->super)) + 1;
1077 ext2fs_block_iterate3(current_fs, inode, BLOCK_FLAG_READ_ONLY, NULL,
1091 retval = ext2fs_check_directory(current_fs, inode);
1138 !ext2fs_test_inode_bitmap2(current_fs->inode_map,inode))
1141 ext2fs_unmark_inode_bitmap2(current_fs->inode_map, inode++);
1142 ext2fs_mark_ib_dirty(current_fs);
1168 ext2fs_test_inode_bitmap2(current_fs->inode_map,inode))
1171 ext2fs_mark_inode_bitmap2(current_fs->inode_map, inode++);
1172 ext2fs_mark_ib_dirty(current_fs);
1183 if (ext2fs_test_inode_bitmap2(current_fs->inode_map,inode))
1200 if (!ext2fs_test_block_bitmap2(current_fs->block_map,block))
1203 ext2fs_unmark_block_bitmap2(current_fs->block_map,block);
1206 ext2fs_mark_bb_dirty(current_fs);
1219 if (ext2fs_test_block_bitmap2(current_fs->block_map,block))
1222 ext2fs_mark_block_bitmap2(current_fs->block_map,block);
1225 ext2fs_mark_bb_dirty(current_fs);
1237 if (ext2fs_test_block_bitmap2(current_fs->block_map,block))
1329 os = current_fs->super->s_creator_os;
1399 retval = ext2fs_check_directory(current_fs, inode);
1417 retval = ext2fs_get_pathname(current_fs, cwd, 0, &pathname);
1428 retval = ext2fs_get_pathname(current_fs, root, 0, &pathname);
1466 if (! (retval=ext2fs_namei(current_fs, root, cwd, destname, &dir)))
1489 retval = ext2fs_link(current_fs, dir, dest, ino,
1536 if (ext2fs_test_inode_bitmap2(current_fs->inode_map, ino)) {
1551 ext2fs_block_iterate3(current_fs, ino, BLOCK_FLAG_READ_ONLY, NULL,
1554 ext2fs_inode_alloc_stats2(current_fs, ino, +1, 0);
1576 retval = ext2fs_unlink(current_fs, dir, base_name, 0, 0);
1652 goal = current_fs->super->s_first_data_block;
1657 retval = ext2fs_new_block2(current_fs, free_blk + 1, 0,
1705 retval = ext2fs_new_inode(current_fs, dir, mode, 0, &free_inode);
1721 retval = do_write_internal(current_fs, cwd, argv[1], argv[2], root);
1770 retval = do_mknod_internal(current_fs, cwd, argv[1], &st);
1783 retval = do_mkdir_internal(current_fs, cwd, argv[1], root);
1808 inode_buf.i_dtime = current_fs->now ? current_fs->now : time(0);
1811 if (ext2fs_inode_has_valid_blocks2(current_fs, &inode_buf)) {
1812 ext2fs_block_iterate3(current_fs, inode, BLOCK_FLAG_READ_ONLY,
1816 ext2fs_inode_alloc_stats2(current_fs, inode, -1,
1841 retval = ext2fs_namei(current_fs, root, cwd, argv[1], &inode_num);
1903 retval = ext2fs_namei(current_fs, root, cwd, argv[1], &inode_num);
1920 retval = ext2fs_dir_iterate2(current_fs, inode_num, 0,
1952 if (current_fs)
1954 current_fs->flags & EXT2_FLAG_RW ? "write" : "only");
1956 current_fs ? current_fs->device_name : "--none--");
1968 retval = ext2fs_expand_dir(current_fs, inode);
1985 ¤t_fs->super->s_feature_compat, 0))
1989 ext2fs_mark_super_dirty(current_fs);
1991 print_features(current_fs->super, stdout);
2045 errcode = ext2fs_bmap2(current_fs, ino, 0, 0, flags, blk,
2070 group = (ino - 1) / EXT2_INODES_PER_GROUP(current_fs->super);
2071 offset = ((ino - 1) % EXT2_INODES_PER_GROUP(current_fs->super)) *
2072 EXT2_INODE_SIZE(current_fs->super);
2073 block = offset >> EXT2_BLOCK_SIZE_BITS(current_fs->super);
2074 if (!ext2fs_inode_table_loc(current_fs, (unsigned)group)) {
2079 block_nr = ext2fs_inode_table_loc(current_fs, (unsigned)group) +
2081 offset &= (EXT2_BLOCK_SIZE(current_fs->super) - 1);
2103 isize = EXT2_INODE_SIZE(current_fs->super);
2110 err = ext2fs_read_inode_full(current_fs, ino,
2139 current_fs->now = now;
2235 errcode = ext2fs_punch(current_fs, ino, 0, 0, start, end);
2270 errcode = ext2fs_fallocate(current_fs, EXT2_FALLOCATE_INIT_BEYOND_EOF,
2290 retval = do_symlink_internal(current_fs, cwd, argv[1], argv[2], root);
2316 mmp_block = current_fs->super->s_mmp_block;
2325 if (current_fs->mmp_buf == NULL) {
2326 retval = ext2fs_get_mem(current_fs->blocksize,
2327 ¤t_fs->mmp_buf);
2334 mmp_s = current_fs->mmp_buf;
2336 retval = ext2fs_mmp_read(current_fs, mmp_block, current_fs->mmp_buf);
2344 fprintf(stdout, "block_number: %llu\n", current_fs->super->s_mmp_block);
2346 current_fs->super->s_mmp_update_interval);
2551 if (current_fs)