diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-09 02:25:45 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-09 02:25:45 -0400 |
commit | 1acc9309eb2674533944f48dbaaa53e7750e3947 (patch) | |
tree | 255f346c01a33906b612852d5fb008da1f4520da /fs/btrfs/inode.c | |
parent | c2d197e82b6267fd3338f3fbcb12750ca9f5abda (diff) | |
parent | 149e2d76b4886c4c7ff5e077646a8ba3563c8026 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable:
btrfs: fix oops when doing space balance
Btrfs: don't panic if we get an error while balancing V2
btrfs: add missing options displayed in mount output
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r-- | fs/btrfs/inode.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index d340f63d8f07..3601f0aebddf 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c | |||
@@ -2678,12 +2678,14 @@ noinline int btrfs_update_inode(struct btrfs_trans_handle *trans, | |||
2678 | int ret; | 2678 | int ret; |
2679 | 2679 | ||
2680 | /* | 2680 | /* |
2681 | * If root is tree root, it means this inode is used to | 2681 | * If the inode is a free space inode, we can deadlock during commit |
2682 | * store free space information. And these inodes are updated | 2682 | * if we put it into the delayed code. |
2683 | * when committing the transaction, so they needn't delaye to | 2683 | * |
2684 | * be updated, or deadlock will occured. | 2684 | * The data relocation inode should also be directly updated |
2685 | * without delay | ||
2685 | */ | 2686 | */ |
2686 | if (!is_free_space_inode(root, inode)) { | 2687 | if (!is_free_space_inode(root, inode) |
2688 | && root->root_key.objectid != BTRFS_DATA_RELOC_TREE_OBJECTID) { | ||
2687 | ret = btrfs_delayed_update_inode(trans, root, inode); | 2689 | ret = btrfs_delayed_update_inode(trans, root, inode); |
2688 | if (!ret) | 2690 | if (!ret) |
2689 | btrfs_set_inode_last_trans(trans, inode); | 2691 | btrfs_set_inode_last_trans(trans, inode); |