Kill the Lite2 early "filesystem clean abort" check and go back to
something closer to how we used to do it. The Lite2 way is to check the "fsclean" flag in the superblock and stop there if so (during preen). We now do the various superblock sanity checks that we used to do before since it's cheap. We now get the filesystem state summary again instead of "FILESYSTEM CLEAN; CHECKING SKIPPED" (or whatever).
This commit is contained in:
parent
ccae52be0e
commit
2d879de2ad
@ -197,10 +197,6 @@ checkfilesys(filesys, mntpt, auxdata, child)
|
||||
pfatal("CAN'T CHECK FILE SYSTEM.");
|
||||
/* fall through */
|
||||
case -1:
|
||||
return (0);
|
||||
}
|
||||
|
||||
if (preen && sblock.fs_clean && !fflag) {
|
||||
pwarn("clean, %ld free ", sblock.fs_cstotal.cs_nffree +
|
||||
sblock.fs_frag * sblock.fs_cstotal.cs_nbfree);
|
||||
printf("(%ld frags, %ld blocks, %.1f%% fragmentation)\n",
|
||||
|
@ -145,10 +145,6 @@ setup(dev)
|
||||
pwarn("USING ALTERNATE SUPERBLOCK AT %d\n", bflag);
|
||||
bflag = 0;
|
||||
}
|
||||
if (skipclean && sblock.fs_clean) {
|
||||
pwarn("FILESYSTEM CLEAN; SKIPPING CHECKS\n");
|
||||
return (-1);
|
||||
}
|
||||
maxfsblock = sblock.fs_size;
|
||||
maxino = sblock.fs_ncg * sblock.fs_ipg;
|
||||
/*
|
||||
@ -264,6 +260,12 @@ setup(dev)
|
||||
asked++;
|
||||
}
|
||||
}
|
||||
/*
|
||||
* If we survive the above basic checks and are preening,
|
||||
* quit here unless forced.
|
||||
*/
|
||||
if (skipclean && sblock.fs_clean && !fflag)
|
||||
return (-1);
|
||||
/*
|
||||
* allocate and initialize the necessary maps
|
||||
*/
|
||||
|
@ -197,10 +197,6 @@ checkfilesys(filesys, mntpt, auxdata, child)
|
||||
pfatal("CAN'T CHECK FILE SYSTEM.");
|
||||
/* fall through */
|
||||
case -1:
|
||||
return (0);
|
||||
}
|
||||
|
||||
if (preen && sblock.fs_clean && !fflag) {
|
||||
pwarn("clean, %ld free ", sblock.fs_cstotal.cs_nffree +
|
||||
sblock.fs_frag * sblock.fs_cstotal.cs_nbfree);
|
||||
printf("(%ld frags, %ld blocks, %.1f%% fragmentation)\n",
|
||||
|
@ -145,10 +145,6 @@ setup(dev)
|
||||
pwarn("USING ALTERNATE SUPERBLOCK AT %d\n", bflag);
|
||||
bflag = 0;
|
||||
}
|
||||
if (skipclean && sblock.fs_clean) {
|
||||
pwarn("FILESYSTEM CLEAN; SKIPPING CHECKS\n");
|
||||
return (-1);
|
||||
}
|
||||
maxfsblock = sblock.fs_size;
|
||||
maxino = sblock.fs_ncg * sblock.fs_ipg;
|
||||
/*
|
||||
@ -264,6 +260,12 @@ setup(dev)
|
||||
asked++;
|
||||
}
|
||||
}
|
||||
/*
|
||||
* If we survive the above basic checks and are preening,
|
||||
* quit here unless forced.
|
||||
*/
|
||||
if (skipclean && sblock.fs_clean && !fflag)
|
||||
return (-1);
|
||||
/*
|
||||
* allocate and initialize the necessary maps
|
||||
*/
|
||||
|
@ -197,10 +197,6 @@ checkfilesys(filesys, mntpt, auxdata, child)
|
||||
pfatal("CAN'T CHECK FILE SYSTEM.");
|
||||
/* fall through */
|
||||
case -1:
|
||||
return (0);
|
||||
}
|
||||
|
||||
if (preen && sblock.fs_clean && !fflag) {
|
||||
pwarn("clean, %ld free ", sblock.fs_cstotal.cs_nffree +
|
||||
sblock.fs_frag * sblock.fs_cstotal.cs_nbfree);
|
||||
printf("(%ld frags, %ld blocks, %.1f%% fragmentation)\n",
|
||||
|
@ -145,10 +145,6 @@ setup(dev)
|
||||
pwarn("USING ALTERNATE SUPERBLOCK AT %d\n", bflag);
|
||||
bflag = 0;
|
||||
}
|
||||
if (skipclean && sblock.fs_clean) {
|
||||
pwarn("FILESYSTEM CLEAN; SKIPPING CHECKS\n");
|
||||
return (-1);
|
||||
}
|
||||
maxfsblock = sblock.fs_size;
|
||||
maxino = sblock.fs_ncg * sblock.fs_ipg;
|
||||
/*
|
||||
@ -264,6 +260,12 @@ setup(dev)
|
||||
asked++;
|
||||
}
|
||||
}
|
||||
/*
|
||||
* If we survive the above basic checks and are preening,
|
||||
* quit here unless forced.
|
||||
*/
|
||||
if (skipclean && sblock.fs_clean && !fflag)
|
||||
return (-1);
|
||||
/*
|
||||
* allocate and initialize the necessary maps
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user