]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: refill block reserves during truncate
authorChris Mason <clm@fb.com>
Wed, 4 Feb 2015 14:59:29 +0000 (06:59 -0800)
committerChris Mason <clm@fb.com>
Fri, 10 Apr 2015 21:06:34 +0000 (14:06 -0700)
commitcba70b0ecb78b67e1d583c9e4f311c4e9d6fe103
tree14c32d9251117f3ec0f771e95ab17c1d96fe2b94
parent9f7241dbcaf1761933263a45ee37061638f378ba
Btrfs: refill block reserves during truncate

When truncate starts, it allocates some space in the block reserves so
that we'll have enough to update metadata along the way.

For very large files, we can easily go through all of that space as we
loop through the extents.  This changes truncate to refill the space
reservation as it progresses through the file.

Signed-off-by: Chris Mason <clm@fb.com>
fs/btrfs/ctree.h
fs/btrfs/extent-tree.c
fs/btrfs/inode.c