@@ -368,9 +368,8 @@ dioread_nolock locking. If the dioread_nolock option is specified
speed storages. However this does not work with
data journaling and dioread_nolock option will be
ignored with kernel warning. Note that dioread_nolock
- code path is only used for extent-based files.
- Because of the restrictions this options comprises
- it is off by default (e.g. dioread_lock).
+ code path is only used for extent-based files. it is
+ on by default for extent-based files.
max_dir_size_kb=n This limits the size of directories so that any
attempt to expand them beyond the specified
@@ -3402,6 +3402,14 @@ static int ext4_fill_super(struct super_block *sb, void *data, int silent)
set_opt(sb, DELALLOC);
/*
+ * enable dioread_nolock by default
+ * Use -o dioread_lock to turn it off
+ */
+ if (!IS_EXT3_SB(sb) && !IS_EXT2_SB(sb) &&
+ EXT4_HAS_INCOMPAT_FEATURE(sb, EXT4_FEATURE_INCOMPAT_EXTENTS))
+ set_opt(sb, DIOREAD_NOLOCK);
+
+ /*
* set default s_li_wait_mult for lazyinit, for the case there is
* no mount option specified.
*/