aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/backref.c
diff options
context:
space:
mode:
authorDavid Sterba <[email protected]>2025-04-17 09:17:02 +0000
committerDavid Sterba <[email protected]>2025-05-15 12:30:47 +0000
commited50ab0fec1a881a379bea7187994ff6cbe2fc58 (patch)
treef9c589fb6a275851d593f2c2016c6a9cd40f9606 /fs/btrfs/backref.c
parentbtrfs: add debug build only WARN (diff)
downloadkernel-ed50ab0fec1a881a379bea7187994ff6cbe2fc58.tar.gz
kernel-ed50ab0fec1a881a379bea7187994ff6cbe2fc58.zip
btrfs: convert WARN_ON(IS_ENABLED(CONFIG_BTRFS_DEBUG)) to DEBUG_WARN
Use the conditional warning instead of typing the whole condition. Optional message is printed where it seems clear what could be the problem. Conversion is left out in btree_csum_one_bio() because of the additional condition. Reviewed-by: Josef Bacik <[email protected]> Signed-off-by: David Sterba <[email protected]>
Diffstat (limited to 'fs/btrfs/backref.c')
-rw-r--r--fs/btrfs/backref.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/backref.c b/fs/btrfs/backref.c
index 5936cff80ff3..e76e1845cfce 100644
--- a/fs/btrfs/backref.c
+++ b/fs/btrfs/backref.c
@@ -2877,7 +2877,7 @@ int btrfs_backref_iter_start(struct btrfs_backref_iter *iter, u64 bytenr)
goto release;
}
if (path->slots[0] == 0) {
- WARN_ON(IS_ENABLED(CONFIG_BTRFS_DEBUG));
+ DEBUG_WARN();
ret = -EUCLEAN;
goto release;
}