| To: | kernel-janitors@xxxxxxxxxxxxxx |
|---|---|
| Subject: | [xfs-masters] [Patch] BUG_ON conversion for fs/xfs/ |
| From: | Eric Sesterhenn <snakebyte@xxxxxx> |
| Date: | Mon, 25 Sep 2006 00:49:21 +0200 |
| Cc: | xfs-masters@xxxxxxxxxxx |
| Reply-to: | xfs-masters@xxxxxxxxxxx |
| Sender: | xfs-masters-bounce@xxxxxxxxxxx |
hi,
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@xxxxxx>
--- linux-2.6.18-git3/fs/xfs/support/debug.c.orig 2006-09-24
23:20:46.000000000 +0200
+++ linux-2.6.18-git3/fs/xfs/support/debug.c 2006-09-24 23:21:05.000000000
+0200
@@ -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,
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
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [xfs-masters] ***** SUSPECTED SPAM ***** YOU ARE A WINNER, NATIONAL LOTTO LOCKY ONLINE |
|---|---|
| Next by Date: | [xfs-masters] [Bug 707] compile failure on PowerPC64 due to linux header problems, bugzilla-daemon |
| Previous by Thread: | [xfs-masters] ***** SUSPECTED SPAM ***** YOU ARE A WINNER, NATIONAL LOTTO LOCKY ONLINE |
| Next by Thread: | [xfs-masters] [Bug 707] compile failure on PowerPC64 due to linux header problems, bugzilla-daemon |
| Indexes: | [Date] [Thread] [Top] [All Lists] |