In commit ab1ca99b51df63901617b9f10f9a36d5d4972d78
(Btrfs: reset to appropriate block rsv after orphan operations),
we miss a block_rsv reset and this sometimes leads us to
the WARNING of btrfs_orphan_commit_root().
Signed-off-by: Liu Bo <liubo2009@cn.fujitsu.com>
---
fs/btrfs/free-space-cache.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/fs/btrfs/free-space-cache.c b/fs/btrfs/free-space-cache.c
index 41ac927..d96815c 100644
--- a/fs/btrfs/free-space-cache.c
+++ b/fs/btrfs/free-space-cache.c
@@ -199,8 +199,10 @@ int btrfs_truncate_free_space_cache(struct btrfs_root
*root,
ret = btrfs_block_rsv_check(trans, root,
root->orphan_block_rsv,
0, 5);
- if (ret)
+ if (ret) {
+ trans->block_rsv = rsv;
return ret;
+ }
oldsize = i_size_read(inode);
btrfs_i_size_write(inode, 0);
--
1.6.5.2
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs"
in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html