OOPS problems

Riley Williams (rhw@bigfoot.com)
Wed, 30 Dec 1998 15:59:14 +0000 (GMT)


Hi there.

There seems to be a lot of people having problems with recording OOPS
messages, so perhaps it ought to be easier to do so?

One apparently obvious means to do so would be to have a 'kernel log
level' for OOPS messages, and let the kernel logging system deal with
it. Since this hasn't been done, I would assume there's something
wrong with this idea, so perhaps somebody can advise me what?

In case there isn't anything wrong with it, the following patch should
set up the relevant facilities...although precicely what log level
should be allocated to OOPS messages is debatable...

===8<=== CUT ===>8===
--- linux/kernel/printk.c.old Fri Nov 20 19:43:19 1998
+++ linux/kernel/printk.c Wed Dec 30 15:43:19 1998
@@ -29,7 +29,7 @@

/* We show everything that is MORE important than this.. */
#define MINIMUM_CONSOLE_LOGLEVEL 1 /* Minimum loglevel we let people use */
-#define DEFAULT_CONSOLE_LOGLEVEL 7 /* anything MORE serious than KERN_DEBUG */
+#define DEFAULT_CONSOLE_LOGLEVEL 8 /* anything MORE serious than KERN_DEBUG */

unsigned long log_size = 0;
struct wait_queue * log_wait = NULL;
--- linux/include/linux/kernel.h.old Tue Dec 1 21:33:00 1998
+++ linux/include/linux/kernel.h Wed Dec 30 15:56:25 1998
@@ -24,12 +24,13 @@
#define KERN_EMERG "<0>" /* system is unusable */
#define KERN_ALERT "<1>" /* action must be taken immediately */
#define KERN_CRIT "<2>" /* critical conditions */
#define KERN_ERR "<3>" /* error conditions */
+#define KERN_OOPS "<4>" /* OOPS report */
-#define KERN_WARNING "<4>" /* warning conditions */
+#define KERN_WARNING "<5>" /* warning conditions */
-#define KERN_NOTICE "<5>" /* normal but significant condition */
+#define KERN_NOTICE "<6>" /* normal but significant condition */
-#define KERN_INFO "<6>" /* informational */
+#define KERN_INFO "<7>" /* informational */
-#define KERN_DEBUG "<7>" /* debug-level messages */
+#define KERN_DEBUG "<8>" /* debug-level messages */

# define NORET_TYPE /**/
# define ATTRIB_NORET __attribute__((noreturn))
# define NORET_AND noreturn,
===8<=== CUT ===>8===

Best wishes from Riley.

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