diff options
author | Jeff Mahoney <jeffm@suse.com> | 2012-03-01 08:56:27 -0500 |
---|---|---|
committer | David Sterba <dsterba@suse.cz> | 2012-03-21 20:45:31 -0400 |
commit | d5c13f927fe77b11a67f79559808c68b26474c77 (patch) | |
tree | 4725c8b83309fa8431fea85bf9acc99b8e015291 /fs/btrfs/disk-io.h | |
parent | d16cb050e5b1c3a9d754fed7098eefb8237877d1 (diff) |
btrfs: clean_tree_block should panic on observed memory corruption and return void
The only error condition in clean_tree_block is an accounting bug.
Returning without modifying dirty_metadata_bytes and as if the cleaning
as been performed may cause problems later so it should panic instead.
It should probably be a BUG_ON but we have btrfs_panic now.
Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Diffstat (limited to 'fs/btrfs/disk-io.h')
-rw-r--r-- | fs/btrfs/disk-io.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/btrfs/disk-io.h b/fs/btrfs/disk-io.h index e4bc4741319b..ca34237ae384 100644 --- a/fs/btrfs/disk-io.h +++ b/fs/btrfs/disk-io.h | |||
@@ -44,8 +44,8 @@ int reada_tree_block_flagged(struct btrfs_root *root, u64 bytenr, u32 blocksize, | |||
44 | int mirror_num, struct extent_buffer **eb); | 44 | int mirror_num, struct extent_buffer **eb); |
45 | struct extent_buffer *btrfs_find_create_tree_block(struct btrfs_root *root, | 45 | struct extent_buffer *btrfs_find_create_tree_block(struct btrfs_root *root, |
46 | u64 bytenr, u32 blocksize); | 46 | u64 bytenr, u32 blocksize); |
47 | int clean_tree_block(struct btrfs_trans_handle *trans, | 47 | void clean_tree_block(struct btrfs_trans_handle *trans, |
48 | struct btrfs_root *root, struct extent_buffer *buf); | 48 | struct btrfs_root *root, struct extent_buffer *buf); |
49 | int open_ctree(struct super_block *sb, | 49 | int open_ctree(struct super_block *sb, |
50 | struct btrfs_fs_devices *fs_devices, | 50 | struct btrfs_fs_devices *fs_devices, |
51 | char *options); | 51 | char *options); |