projects/linux·commit b231125a

printk: add KERN_DEFAULT loglevel to print_modules()

b231125a · Linus Torvalds <[email protected]> · 2009-06-16 11:07:14 -07:00

Several WARN_ON() messages omit the '\n' at the end of the string, which
is a simple (and understandable) error.  The next line printed after
that warning line is usually the current module list, and that printk
does not have a log-level marker - resulting in one long mixed-up line.

Adding this loglevel marker will now avoid this unreadable mess.

Signed-off-by: Linus Torvalds <[email protected]>
Commit
b231125af7811a2f68c455d3bda95ac170ee4fa6
Parents
e28d7137

Changes

1 files changed · +1 −1

FileStatusAddDelContent
kernel/module.cmodified+1−1View file

kernel/module.c

View file
diff --git a/kernel/module.c b/kernel/module.c
index e4ab36c..215aaab 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -2899,7 +2899,7 @@ void print_modules(void)
struct module *mod;
char buf[8];
- printk("Modules linked in:");
+ printk(KERN_DEFAULT "Modules linked in:");
/* Most callers should already have preempt disabled, but make sure */
preempt_disable();
list_for_each_entry_rcu(mod, &modules, list)