ext4: Enable extents by default

Turn on extents feature by default in ext4 filesystem, to get wider
testing of extents feature in ext4dev.  This can be disabled using 
-o noextents.  

Signed-off-by: Mingming Cao <cmm@us.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
This commit is contained in:
Mingming Cao 2007-07-18 09:00:55 -04:00 committed by Theodore Ts'o
parent 749269faca
commit 1e2462f93e
1 changed files with 11 additions and 1 deletions

View File

@ -734,7 +734,7 @@ enum {
Opt_usrjquota, Opt_grpjquota, Opt_offusrjquota, Opt_offgrpjquota,
Opt_jqfmt_vfsold, Opt_jqfmt_vfsv0, Opt_quota, Opt_noquota,
Opt_ignore, Opt_barrier, Opt_err, Opt_resize, Opt_usrquota,
Opt_grpquota, Opt_extents,
Opt_grpquota, Opt_extents, Opt_noextents,
};
static match_table_t tokens = {
@ -785,6 +785,7 @@ static match_table_t tokens = {
{Opt_usrquota, "usrquota"},
{Opt_barrier, "barrier=%u"},
{Opt_extents, "extents"},
{Opt_noextents, "noextents"},
{Opt_err, NULL},
{Opt_resize, "resize"},
};
@ -1120,6 +1121,9 @@ clear_qf_name:
case Opt_extents:
set_opt (sbi->s_mount_opt, EXTENTS);
break;
case Opt_noextents:
clear_opt (sbi->s_mount_opt, EXTENTS);
break;
default:
printk (KERN_ERR
"EXT4-fs: Unrecognized mount option \"%s\" "
@ -1551,6 +1555,12 @@ static int ext4_fill_super (struct super_block *sb, void *data, int silent)
set_opt(sbi->s_mount_opt, RESERVATION);
/*
* turn on extents feature by default in ext4 filesystem
* User -o noextents to turn it off
*/
set_opt(sbi->s_mount_opt, EXTENTS);
if (!parse_options ((char *) data, sb, &journal_inum, &journal_devnum,
NULL, 0))
goto failed_mount;