diff options
author | Eric Sandeen <sandeen@redhat.com> | 2013-04-25 16:41:01 -0400 |
---|---|---|
committer | Josef Bacik <jbacik@fusionio.com> | 2013-05-06 15:55:23 -0400 |
commit | 48a3b6366f6913683563d934eb16fea67dead9c1 (patch) | |
tree | eb26170d3a5ddb6f81ae612db21fb8fba14e655d /fs/btrfs/compression.c | |
parent | 634554dc0acfc8753c05e432b2fdb34b0be89c78 (diff) |
btrfs: make static code static & remove dead code
Big patch, but all it does is add statics to functions which
are in fact static, then remove the associated dead-code fallout.
removed functions:
btrfs_iref_to_path()
__btrfs_lookup_delayed_deletion_item()
__btrfs_search_delayed_insertion_item()
__btrfs_search_delayed_deletion_item()
find_eb_for_page()
btrfs_find_block_group()
range_straddles_pages()
extent_range_uptodate()
btrfs_file_extent_length()
btrfs_scrub_cancel_devid()
btrfs_start_transaction_lflush()
btrfs_print_tree() is left because it is used for debugging.
btrfs_start_transaction_lflush() and btrfs_reada_detach() are
left for symmetry.
ulist.c functions are left, another patch will take care of those.
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Diffstat (limited to 'fs/btrfs/compression.c')
-rw-r--r-- | fs/btrfs/compression.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/fs/btrfs/compression.c b/fs/btrfs/compression.c index b9c565028605..b189bd1e7a3e 100644 --- a/fs/btrfs/compression.c +++ b/fs/btrfs/compression.c | |||
@@ -82,6 +82,10 @@ struct compressed_bio { | |||
82 | u32 sums; | 82 | u32 sums; |
83 | }; | 83 | }; |
84 | 84 | ||
85 | static int btrfs_decompress_biovec(int type, struct page **pages_in, | ||
86 | u64 disk_start, struct bio_vec *bvec, | ||
87 | int vcnt, size_t srclen); | ||
88 | |||
85 | static inline int compressed_bio_size(struct btrfs_root *root, | 89 | static inline int compressed_bio_size(struct btrfs_root *root, |
86 | unsigned long disk_size) | 90 | unsigned long disk_size) |
87 | { | 91 | { |
@@ -738,7 +742,7 @@ static int comp_num_workspace[BTRFS_COMPRESS_TYPES]; | |||
738 | static atomic_t comp_alloc_workspace[BTRFS_COMPRESS_TYPES]; | 742 | static atomic_t comp_alloc_workspace[BTRFS_COMPRESS_TYPES]; |
739 | static wait_queue_head_t comp_workspace_wait[BTRFS_COMPRESS_TYPES]; | 743 | static wait_queue_head_t comp_workspace_wait[BTRFS_COMPRESS_TYPES]; |
740 | 744 | ||
741 | struct btrfs_compress_op *btrfs_compress_op[] = { | 745 | static struct btrfs_compress_op *btrfs_compress_op[] = { |
742 | &btrfs_zlib_compress, | 746 | &btrfs_zlib_compress, |
743 | &btrfs_lzo_compress, | 747 | &btrfs_lzo_compress, |
744 | }; | 748 | }; |
@@ -909,8 +913,9 @@ int btrfs_compress_pages(int type, struct address_space *mapping, | |||
909 | * be contiguous. They all correspond to the range of bytes covered by | 913 | * be contiguous. They all correspond to the range of bytes covered by |
910 | * the compressed extent. | 914 | * the compressed extent. |
911 | */ | 915 | */ |
912 | int btrfs_decompress_biovec(int type, struct page **pages_in, u64 disk_start, | 916 | static int btrfs_decompress_biovec(int type, struct page **pages_in, |
913 | struct bio_vec *bvec, int vcnt, size_t srclen) | 917 | u64 disk_start, struct bio_vec *bvec, |
918 | int vcnt, size_t srclen) | ||
914 | { | 919 | { |
915 | struct list_head *workspace; | 920 | struct list_head *workspace; |
916 | int ret; | 921 | int ret; |