summaryrefslogtreecommitdiff
path: root/fs/btrfs/file.c
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2008-01-29 21:03:38 (GMT)
committerChris Mason <chris.mason@oracle.com>2008-09-25 15:04:00 (GMT)
commit6f568d35a045dbb8a13fe71bfc32e85e39a986cb (patch)
treedf5cb5826dfb46a2514bfba34f8473dc65ea7081 /fs/btrfs/file.c
parent291d673e6a22d9c6834e939f66c7cfef90669021 (diff)
downloadlinux-fsl-qoriq-6f568d35a045dbb8a13fe71bfc32e85e39a986cb.tar.xz
Btrfs: mount -o max_inline=size to control the maximum inline extent size
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/file.c')
-rw-r--r--fs/btrfs/file.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/btrfs/file.c b/fs/btrfs/file.c
index 8e21061..7c10a90 100644
--- a/fs/btrfs/file.c
+++ b/fs/btrfs/file.c
@@ -301,7 +301,8 @@ static int noinline dirty_and_release_pages(struct btrfs_trans_handle *trans,
*/
inline_size = end_pos;
if (isize >= BTRFS_MAX_INLINE_DATA_SIZE(root) ||
- inline_size > 8192 ||
+ inline_size > root->fs_info->max_inline ||
+ (inline_size & (root->sectorsize -1)) == 0 ||
inline_size >= BTRFS_MAX_INLINE_DATA_SIZE(root)) {
u64 last_end;
u64 existing_delalloc = 0;