summaryrefslogtreecommitdiff
path: root/fs/btrfs/backref.h
diff options
context:
space:
mode:
authorQu Wenruo <wqu@suse.com>2020-03-26 14:21:36 +0800
committerDavid Sterba <dsterba@suse.com>2020-05-25 11:25:21 +0200
commit982c92cbd51cf6ab1319e1e94dfd4902d3678d9a (patch)
tree9e4176aeeb6fe886ca44a285ae667bd8b6e399c8 /fs/btrfs/backref.h
parent13fe1bdb22f8302afa5e588e89a7a94606ef35fb (diff)
btrfs: backref: rename and move backref_tree_panic()
Also change the parameter, since all callers can easily grab an fs_info, there is no need for all the pointer chasing. Signed-off-by: Qu Wenruo <wqu@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/backref.h')
-rw-r--r--fs/btrfs/backref.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/fs/btrfs/backref.h b/fs/btrfs/backref.h
index 5fb38dfb6440..a7697de925d5 100644
--- a/fs/btrfs/backref.h
+++ b/fs/btrfs/backref.h
@@ -355,4 +355,12 @@ void btrfs_backref_cleanup_node(struct btrfs_backref_cache *cache,
void btrfs_backref_release_cache(struct btrfs_backref_cache *cache);
+static inline void btrfs_backref_panic(struct btrfs_fs_info *fs_info,
+ u64 bytenr, int errno)
+{
+ btrfs_panic(fs_info, errno,
+ "Inconsistency in backref cache found at offset %llu",
+ bytenr);
+}
+
#endif