diff options
-rw-r--r-- | fs/btrfs/inode.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 246397d8478f..1f013c5c36aa 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c | |||
@@ -2758,7 +2758,16 @@ static struct btrfs_trans_handle *__unlink_start_trans(struct inode *dir, | |||
2758 | u64 ino = btrfs_ino(inode); | 2758 | u64 ino = btrfs_ino(inode); |
2759 | u64 dir_ino = btrfs_ino(dir); | 2759 | u64 dir_ino = btrfs_ino(dir); |
2760 | 2760 | ||
2761 | trans = btrfs_start_transaction(root, 10); | 2761 | /* |
2762 | * 1 for the possible orphan item | ||
2763 | * 1 for the dir item | ||
2764 | * 1 for the dir index | ||
2765 | * 1 for the inode ref | ||
2766 | * 1 for the inode ref in the tree log | ||
2767 | * 2 for the dir entries in the log | ||
2768 | * 1 for the inode | ||
2769 | */ | ||
2770 | trans = btrfs_start_transaction(root, 8); | ||
2762 | if (!IS_ERR(trans) || PTR_ERR(trans) != -ENOSPC) | 2771 | if (!IS_ERR(trans) || PTR_ERR(trans) != -ENOSPC) |
2763 | return trans; | 2772 | return trans; |
2764 | 2773 | ||