diff options
author | Chris Mason <chris.mason@oracle.com> | 2007-11-01 16:28:41 +0100 |
---|---|---|
committer | Chris Mason <chris.mason@oracle.com> | 2008-09-25 17:03:57 +0200 |
commit | 179e29e488cc74f1e9bd67bc45f70b832740e9ec (patch) | |
tree | aa055d77b8d3f2b4bc59b1bb8a5b98ec0b223fb5 /fs/btrfs/file-item.c | |
parent | Btrfs: Fix PAGE_CACHE_SHIFT shifts on 32 bit machines (diff) | |
download | linux-179e29e488cc74f1e9bd67bc45f70b832740e9ec.tar.xz linux-179e29e488cc74f1e9bd67bc45f70b832740e9ec.zip |
Btrfs: Fix a number of inline extent problems that Yan Zheng reported.
The fixes do a number of things:
1) Most btrfs_drop_extent callers will try to leave the inline extents in
place. It can truncate bytes off the beginning of the inline extent if
required.
2) writepage can now update the inline extent, allowing mmap writes to
go directly into the inline extent.
3) btrfs_truncate_in_transaction truncates inline extents
4) extent_map.c fixed to not merge inline extent mappings and hole
mappings together
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/file-item.c')
-rw-r--r-- | fs/btrfs/file-item.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/file-item.c b/fs/btrfs/file-item.c index 7eb9a5412e2f..614176e52851 100644 --- a/fs/btrfs/file-item.c +++ b/fs/btrfs/file-item.c @@ -291,7 +291,7 @@ int btrfs_csum_truncate(struct btrfs_trans_handle *trans, new_item_size = blocks * BTRFS_CRC32_SIZE; if (new_item_size >= btrfs_item_size_nr(leaf, slot)) return 0; - ret = btrfs_truncate_item(trans, root, path, new_item_size); + ret = btrfs_truncate_item(trans, root, path, new_item_size, 1); BUG_ON(ret); return ret; } |