summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2009-10-13 16:55:09 (GMT)
committerChris Mason <chris.mason@oracle.com>2009-10-13 17:35:11 (GMT)
commit4722607db6a78bd7748c51fa4c8d7371da797254 (patch)
tree83c483a3f55d3f024863e1e33c3ac123e688c868 /fs
parentac6889cbb254be1ffea376bea4a96ce9be0e0ed0 (diff)
downloadlinux-4722607db6a78bd7748c51fa4c8d7371da797254.tar.xz
Btrfs: only write one super copy during fsync
During a tree-log commit for fsync, we've been writing at least two copies of the super block and forcing them to disk. The other filesystems write only one, and this change brings us on par with them. A full transaction commit will write all the super copies, so we still have redundant info written on a regular basis. Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/btrfs/tree-log.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c
index 78f6254..6d9ec28 100644
--- a/fs/btrfs/tree-log.c
+++ b/fs/btrfs/tree-log.c
@@ -2092,7 +2092,7 @@ int btrfs_sync_log(struct btrfs_trans_handle *trans,
* the running transaction open, so a full commit can't hop
* in and cause problems either.
*/
- write_ctree_super(trans, root->fs_info->tree_root, 2);
+ write_ctree_super(trans, root->fs_info->tree_root, 1);
ret = 0;
out_wake_log_root: