Commit 9ab5aa91 authored by Eric Sesterhenn's avatar Eric Sesterhenn Committed by Adrian Bunk

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: default avatarEric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: default avatarAdrian Bunk <bunk@stusta.de>
parent 73dff8be
...@@ -53,8 +53,7 @@ cmn_err(register int level, char *fmt, ...) ...@@ -53,8 +53,7 @@ cmn_err(register int level, char *fmt, ...)
va_end(ap); va_end(ap);
spin_unlock_irqrestore(&xfs_err_lock,flags); spin_unlock_irqrestore(&xfs_err_lock,flags);
if (level == CE_PANIC) BUG_ON(level == CE_PANIC);
BUG();
} }
void void
...@@ -72,8 +71,7 @@ icmn_err(register int level, char *fmt, va_list ap) ...@@ -72,8 +71,7 @@ icmn_err(register int level, char *fmt, va_list ap)
strcat(message, "\n"); strcat(message, "\n");
spin_unlock_irqrestore(&xfs_err_lock,flags); spin_unlock_irqrestore(&xfs_err_lock,flags);
printk("%s%s", err_level[level], message); printk("%s%s", err_level[level], message);
if (level == CE_PANIC) BUG_ON(level == CE_PANIC);
BUG();
} }
void void
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment