diff options
Diffstat (limited to 'fs/btrfs/extent-tree.c')
-rw-r--r-- | fs/btrfs/extent-tree.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c index 0c097f3aec41..bcd59c7dfb57 100644 --- a/fs/btrfs/extent-tree.c +++ b/fs/btrfs/extent-tree.c | |||
@@ -3412,7 +3412,7 @@ again: | |||
3412 | * our reservation. | 3412 | * our reservation. |
3413 | */ | 3413 | */ |
3414 | if (unused <= space_info->total_bytes) { | 3414 | if (unused <= space_info->total_bytes) { |
3415 | unused -= space_info->total_bytes; | 3415 | unused = space_info->total_bytes - unused; |
3416 | if (unused >= num_bytes) { | 3416 | if (unused >= num_bytes) { |
3417 | if (!reserved) | 3417 | if (!reserved) |
3418 | space_info->bytes_reserved += orig_bytes; | 3418 | space_info->bytes_reserved += orig_bytes; |