diff --git a/fs/btrfs/extent-io-tree.c b/fs/btrfs/extent-io-tree.c index c907147c8c619f91223d1a72bd777a7a4bc84086..4571e598ff8b45404a2c87ec199d68764af982b8 100644 --- a/fs/btrfs/extent-io-tree.c +++ b/fs/btrfs/extent-io-tree.c @@ -46,9 +46,11 @@ static inline void btrfs_extent_state_leak_debug_check(void) } } -void __btrfs_debug_check_extent_io_range(const char *caller, - struct extent_io_tree *tree, u64 start, - u64 end) +#define btrfs_debug_check_extent_io_range(tree, start, end) \ + __btrfs_debug_check_extent_io_range(__func__, (tree), (start), (end)) +static inline void __btrfs_debug_check_extent_io_range(const char *caller, + struct extent_io_tree *tree, + u64 start, u64 end) { struct inode *inode = tree->private_data; u64 isize; @@ -67,6 +69,7 @@ void __btrfs_debug_check_extent_io_range(const char *caller, #define btrfs_leak_debug_add_state(state) do {} while (0) #define btrfs_leak_debug_del_state(state) do {} while (0) #define btrfs_extent_state_leak_debug_check() do {} while (0) +#define btrfs_debug_check_extent_io_range(c, s, e) do {} while (0) #endif /* diff --git a/fs/btrfs/extent-io-tree.h b/fs/btrfs/extent-io-tree.h index 92cbb1dc5ce2096c890a3e2b865f55e93de80fcc..564378b6f5140f1119d24e55c2dc165e1435e801 100644 --- a/fs/btrfs/extent-io-tree.h +++ b/fs/btrfs/extent-io-tree.h @@ -269,16 +269,6 @@ static inline bool extent_state_in_tree(const struct extent_state *state) return !RB_EMPTY_NODE(&state->rb_node); } -#ifdef CONFIG_BTRFS_DEBUG -void __btrfs_debug_check_extent_io_range(const char *caller, - struct extent_io_tree *tree, u64 start, - u64 end); -#define btrfs_debug_check_extent_io_range(tree, start, end) \ - __btrfs_debug_check_extent_io_range(__func__, (tree), (start), (end)) -#else -#define btrfs_debug_check_extent_io_range(c, s, e) do {} while (0) -#endif - struct tree_entry { u64 start; u64 end;