Home | History | Annotate | Download | only in e2fsck

Lines Matching refs:fs

106 	ext2_filsys fs = ctx->fs;
117 inodes = fs->super->s_inodes_count;
118 inodes_used = (fs->super->s_inodes_count -
119 fs->super->s_free_inodes_count);
120 blocks = fs->super->s_blocks_count;
121 blocks_used = (fs->super->s_blocks_count -
122 fs->super->s_free_blocks_count);
292 ext2_filsys fs = ctx->fs;
309 lastcheck = fs->super->s_lastcheck;
312 if ((fs->super->s_state & EXT2_ERROR_FS) ||
313 !ext2fs_test_valid(fs))
315 else if ((fs->super->s_state & EXT2_VALID_FS) == 0)
319 else if ((fs->super->s_max_mnt_count > 0) &&
320 (fs->super->s_mnt_count >=
321 (unsigned) fs->super->s_max_mnt_count)) {
323 reason_arg = fs->super->s_mnt_count;
324 if (batt && (fs->super->s_mnt_count <
325 (unsigned) fs->super->s_max_mnt_count*2))
327 } else if (fs->super->s_checkinterval && (ctx->now < lastcheck)) {
331 } else if (fs->super->s_checkinterval &&
333 ((time_t) fs->super->s_checkinterval))) {
335 reason_arg = (ctx->now - fs->super->s_lastcheck)/(3600*24);
336 if (batt && ((ctx->now - fs->super->s_lastcheck) <
337 fs->super->s_checkinterval*2))
347 fs->super->s_inodes_count - fs->super->s_free_inodes_count,
348 fs->super->s_inodes_count,
349 fs->super->s_blocks_count - fs->super->s_free_blocks_count,
350 fs->super->s_blocks_count);
352 if (fs->super->s_max_mnt_count > 0) {
353 next_check = fs->super->s_max_mnt_count - fs->super->s_mnt_count;
357 if (fs->super->s_checkinterval &&
358 ((ctx->now - fs->super->s_lastcheck) >= fs->super->s_checkinterval))
371 ext2fs_close(fs);
372 ctx->fs = NULL;
950 ext2_filsys fs = 0;
1028 retval = try_open_fs(ctx, flags, io_ptr, &fs);
1034 ((retval == 0) && (retval2 = ext2fs_check_desc(fs))))) {
1039 if (fs->flags & EXT2_FLAG_NOFREE_ON_ERROR) {
1040 ext2fs_free(fs);
1041 fs = NULL;
1043 if (!fs || (fs->group_desc_count > 1)) {
1049 get_backup_sb(ctx, fs, ctx->filesystem_name, io_ptr);
1050 if (fs)
1051 ext2fs_close(fs);
1053 retval = try_open_fs(ctx, flags, io_ptr, &fs);
1060 retval = try_open_fs(ctx, flags, io_ptr, &fs);
1066 fs && fs->super) {
1067 sb = fs->super;
1122 fs->flags |= EXT2_FLAG_MASTER_SB_ONLY;
1125 __u32 blocksize = EXT2_BLOCK_SIZE(fs->super);
1139 ext2fs_close(fs);
1158 ctx->fs = fs;
1159 fs->priv_data = ctx;
1160 fs->now = ctx->now;
1161 sb = fs->super;
1185 ehandler_init(fs->io);
1211 io_channel_flush(ctx->fs->io);
1231 ext2fs_close(ctx->fs);
1232 ctx->fs = 0;
1287 ext2fs_mark_super_dirty(fs);
1291 * fs->blocksize > page_size, set the number of blocks per
1299 ctx->blocks_per_page = sys_page_size / fs->blocksize;
1305 ext2fs_mark_valid(fs);
1321 ext2fs_mark_valid(fs);
1323 retval = ext2fs_read_bb_inode(fs, &fs->badblocks);
1348 journal_size = ext2fs_default_journal_size(fs->super->s_blocks_count);
1350 fs->super->s_feature_compat &=
1352 fs->flags &= ~EXT2_FLAG_MASTER_SB_ONLY;
1360 retval = ext2fs_add_journal_inode(fs,
1382 ext2fs_close(fs);
1393 fs->flags &= ~EXT2_FLAG_MASTER_SB_ONLY;
1394 ext2fs_mark_super_dirty(fs);
1400 if (ext2fs_test_changed(fs)) {
1411 if (!ext2fs_test_valid(fs) ||
1426 if (allow_cancellation && ext2fs_test_valid(fs) &&
1433 if (ext2fs_test_valid(fs)) {
1441 ext2fs_mark_super_dirty(fs);
1447 retval = ext2fs_set_gdt_csum(ctx->fs);
1456 io_channel_flush(ctx->fs->io);
1457 print_resource_track(ctx, NULL, &ctx->global_rtrack, ctx->fs->io);
1459 ext2fs_close(fs);
1460 ctx->fs = NULL;