Hello Ted,
here is a patch against 1.20 which fixes up the creation of rev 0 filesystems.
It is possible to prperly select (via -r and -s flags) which version a new
fs is, and also to select whether or not the filesystem has sparse
superblocks. With the current mke2fs, a rev 0 filesystem will still have
sparse superblocks (-r 0 -s 0), and a rev 1 filesystem will have sparse
superblocks even when told not to (-r 1 -s 0). The default is still to have
sparse superblocks.
I think you already have the first part of the patch (printf cleanup from
changes in 1.19), but in case not...
Cheers, Andreas
--- mke2fs.c.orig Mon Aug 14 11:30:34 2000
+++ mke2fs.c Mon Oct 23 20:50:17 2000
@@ -559,7 +559,7 @@
retval = io_channel_write_blk(fs->io, sect, -512, buf);
io_channel_set_blksize(fs->io, fs->blocksize);
if (retval)
- printf(_("Warning: could not erase block 0: %s\n"),
+ printf(_("Warning: could not erase block %d: %s\n"), sect,
error_message(retval));
}
@@ -736,12 +736,12 @@
int reserved_ratio = 5;
ino_t num_inodes = 0;
errcode_t retval;
- int sparse_option = 0;
+ int sparse_option = 1;
char * oldpath = getenv("PATH");
struct ext2fs_sb *param_ext2 = (struct ext2fs_sb *) ¶m;
char * raid_opts = 0;
char * fs_type = 0;
- const char * feature_set = "filetype,sparse_super";
+ const char * feature_set = "filetype";
blk_t dev_size;
#ifdef linux
struct utsname ut;
@@ -995,6 +995,11 @@
param.s_r_blocks_count = (param.s_blocks_count * reserved_ratio) / 100;
#ifdef EXT2_FEATURE_RO_COMPAT_SPARSE_SUPER
+ /* Turn off features not supported by the earlier filesystem version */
+ if (param.s_rev_level == 0) {
+ sparse_option = 0;
+ feature_set = NULL;
+ }
if (sparse_option)
param_ext2->s_feature_ro_compat |=
EXT2_FEATURE_RO_COMPAT_SPARSE_SUPER;
-
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to [EMAIL PROTECTED]