summaryrefslogtreecommitdiffstats
path: root/fs/xfs/support/debug.c
diff options
context:
space:
mode:
authorEric Sesterhenn <snakebyte@gmx.de>2006-10-03 23:37:55 +0200
committerAdrian Bunk <bunk@stusta.de>2006-10-03 23:37:55 +0200
commit9ab5aa911a5b5d7c721436bce8709202b707a361 (patch)
treee24fdd1d911415bf5d15c1bf2950766c8c04543e /fs/xfs/support/debug.c
parent73dff8be9ea89df26bfb6a0443ad912de6e7bd00 (diff)
downloadop-kernel-dev-9ab5aa911a5b5d7c721436bce8709202b707a361.zip
op-kernel-dev-9ab5aa911a5b5d7c721436bce8709202b707a361.tar.gz
BUG_ON conversion for fs/xfs/
This patch converts two if () BUG(); construct to BUG_ON(); which occupies less space, uses unlikely and is safer when BUG() is disabled. Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Signed-off-by: Adrian Bunk <bunk@stusta.de>
Diffstat (limited to 'fs/xfs/support/debug.c')
-rw-r--r--fs/xfs/support/debug.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/xfs/support/debug.c b/fs/xfs/support/debug.c
index 36fbecc..c75f683 100644
--- a/fs/xfs/support/debug.c
+++ b/fs/xfs/support/debug.c
@@ -53,8 +53,7 @@ cmn_err(register int level, char *fmt, ...)
va_end(ap);
spin_unlock_irqrestore(&xfs_err_lock,flags);
- if (level == CE_PANIC)
- BUG();
+ BUG_ON(level == CE_PANIC);
}
void
@@ -72,8 +71,7 @@ icmn_err(register int level, char *fmt, va_list ap)
strcat(message, "\n");
spin_unlock_irqrestore(&xfs_err_lock,flags);
printk("%s%s", err_level[level], message);
- if (level == CE_PANIC)
- BUG();
+ BUG_ON(level == CE_PANIC);
}
void
OpenPOWER on IntegriCloud