* [PATCH] btrfs: Remove redundant forward declarations
@ 2017-08-31 8:48 Nikolay Borisov
2017-09-06 14:23 ` David Sterba
0 siblings, 1 reply; 2+ messages in thread
From: Nikolay Borisov @ 2017-08-31 8:48 UTC (permalink / raw)
To: linux-btrfs; +Cc: dsterba, Nikolay Borisov
Some static functions are needlessly forward declared. Let's remove those
declarations since they add no value.
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
---
Here is a less invasive version of my previous patch removing the fwd
declarations in extent-tree. This time I've limited myself to only those
declarations which can be removed without moving code around and creating
needless noise.
fs/btrfs/extent-tree.c | 12 ------------
1 file changed, 12 deletions(-)
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c
index 21c78c48e15b..4c9e87efdaa1 100644
--- a/fs/btrfs/extent-tree.c
+++ b/fs/btrfs/extent-tree.c
@@ -61,9 +61,6 @@ enum {
CHUNK_ALLOC_FORCE = 2,
};
-static int update_block_group(struct btrfs_trans_handle *trans,
- struct btrfs_fs_info *fs_info, u64 bytenr,
- u64 num_bytes, int alloc);
static int __btrfs_free_extent(struct btrfs_trans_handle *trans,
struct btrfs_fs_info *fs_info,
struct btrfs_delayed_ref_node *node, u64 parent,
@@ -91,17 +88,8 @@ static int find_next_key(struct btrfs_path *path, int level,
static void dump_space_info(struct btrfs_fs_info *fs_info,
struct btrfs_space_info *info, u64 bytes,
int dump_block_groups);
-static int btrfs_add_reserved_bytes(struct btrfs_block_group_cache *cache,
- u64 ram_bytes, u64 num_bytes, int delalloc);
-static int btrfs_free_reserved_bytes(struct btrfs_block_group_cache *cache,
- u64 num_bytes, int delalloc);
static int block_rsv_use_bytes(struct btrfs_block_rsv *block_rsv,
u64 num_bytes);
-static int __reserve_metadata_bytes(struct btrfs_fs_info *fs_info,
- struct btrfs_space_info *space_info,
- u64 orig_bytes,
- enum btrfs_reserve_flush_enum flush,
- bool system_chunk);
static void space_info_add_new_bytes(struct btrfs_fs_info *fs_info,
struct btrfs_space_info *space_info,
u64 num_bytes);
--
2.7.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] btrfs: Remove redundant forward declarations
2017-08-31 8:48 [PATCH] btrfs: Remove redundant forward declarations Nikolay Borisov
@ 2017-09-06 14:23 ` David Sterba
0 siblings, 0 replies; 2+ messages in thread
From: David Sterba @ 2017-09-06 14:23 UTC (permalink / raw)
To: Nikolay Borisov; +Cc: linux-btrfs, dsterba
On Thu, Aug 31, 2017 at 11:48:51AM +0300, Nikolay Borisov wrote:
> Some static functions are needlessly forward declared. Let's remove those
> declarations since they add no value.
>
> Signed-off-by: Nikolay Borisov <nborisov@suse.com>
> ---
>
> Here is a less invasive version of my previous patch removing the fwd
> declarations in extent-tree. This time I've limited myself to only those
> declarations which can be removed without moving code around and creating
> needless noise.
I can't find the previous patches, but this one is ok. This kind of
cleanup can be done in one big patch, if you are going to send more.
Reviewed-by: David Sterba <dsterba@suse.com>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-09-06 14:24 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-31 8:48 [PATCH] btrfs: Remove redundant forward declarations Nikolay Borisov
2017-09-06 14:23 ` David Sterba
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).