lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 15 Jul 2007 21:36:59 -0300
From:	Diego Woitasen <diego@...tasen.com.ar>
To:	linux-kernel@...r.kernel.org
Cc:	Diego Woitasen <diego@...tasen.com.ar>
Subject: [PATCH] Add KERN_* prefix to printks in bug.h

---
 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

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ