From: Diego Woitasen <diego@woitasen.com.ar>
To: linux-kernel@vger.kernel.org
Cc: Diego Woitasen <diego@woitasen.com.ar>
Subject: [PATCH] Add KERN_* prefix to printks in bug.h
Date: Sun, 15 Jul 2007 21:36:59 -0300 [thread overview]
Message-ID: <11845462192199-git-send-email-diego@woitasen.com.ar> (raw)
---
include/asm-generic/bug.h | 25 +++++++++++++------------
1 files changed, 13 insertions(+), 12 deletions(-)
diff --git a/include/asm-generic/bug.h b/include/asm-generic/bug.h
index 7f30cce..6e49266 100644
--- a/include/asm-generic/bug.h
+++ b/include/asm-generic/bug.h
@@ -8,22 +8,23 @@
#ifdef CONFIG_GENERIC_BUG
#ifndef __ASSEMBLY__
struct bug_entry {
- unsigned long bug_addr;
+ unsigned long bug_addr;
#ifdef CONFIG_DEBUG_BUGVERBOSE
- const char *file;
- unsigned short line;
+ const char *file;
+ unsigned short line;
#endif
- unsigned short flags;
+ unsigned short flags;
};
-#endif /* __ASSEMBLY__ */
+#endif /* __ASSEMBLY__ */
#define BUGFLAG_WARNING (1<<0)
-#endif /* CONFIG_GENERIC_BUG */
+#endif /* CONFIG_GENERIC_BUG */
#ifndef HAVE_ARCH_BUG
-#define BUG() do { \
- printk("BUG: failure at %s:%d/%s()!\n", __FILE__, __LINE__, __FUNCTION__); \
- panic("BUG!"); \
+#define BUG() do { \
+ printk(KERN_EMERG "BUG: failure at %s:%d/%s()!\n", \
+ __FILE__, __LINE__, __FUNCTION__); \
+ panic("BUG!"); \
} while (0)
#endif
@@ -35,15 +36,15 @@ struct bug_entry {
#define WARN_ON(condition) ({ \
typeof(condition) __ret_warn_on = (condition); \
if (unlikely(__ret_warn_on)) { \
- printk("WARNING: at %s:%d %s()\n", __FILE__, \
- __LINE__, __FUNCTION__); \
+ printk(KERN_WARNING "WARNING: at %s:%d %s()\n", \
+ __FILE__, __LINE__, __FUNCTION__); \
dump_stack(); \
} \
unlikely(__ret_warn_on); \
})
#endif
-#else /* !CONFIG_BUG */
+#else /* !CONFIG_BUG */
#ifndef HAVE_ARCH_BUG
#define BUG()
#endif
--
1.5.2.3
next reply other threads:[~2007-07-16 0:37 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-16 0:36 Diego Woitasen [this message]
2007-07-16 4:45 ` Alexey Dobriyan
2007-07-16 12:45 ` Diego Woitasen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=11845462192199-git-send-email-diego@woitasen.com.ar \
--to=diego@woitasen.com.ar \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®