aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/kernel.h
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-06-16 13:57:02 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-06-16 13:57:02 -0400
commit5fd29d6ccbc98884569d6f3105aeca70858b3e0f (patch)
tree93ac507debc6b35e5863116086c57170618099cf /include/linux/kernel.h
parent03347e2592078a90df818670fddf97a33eec70fb (diff)
printk: clean up handling of log-levels and newlines
It used to be that we would only look at the log-level in a printk() after explicit newlines, which can cause annoying problems when the previous printk() did not end with a '\n'. In that case, the log-level marker would be just printed out in the middle of the line, and be seen as just noise rather than change the logging level. This changes things to always look at the log-level in the first bytes of the printout. If a log level marker is found, it is always used as the log-level. Additionally, if no newline existed, one is added (unless the log-level is the explicit KERN_CONT marker, to explicitly show that it's a continuation of a previous line). Acked-by: Arjan van de Ven <arjan@infradead.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/kernel.h')
-rw-r--r--include/linux/kernel.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index 883cd44ff765..066bb1eddfea 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -102,7 +102,7 @@ extern const char linux_proc_banner[];
102 * line that had no enclosing \n). Only to be used by core/arch code 102 * line that had no enclosing \n). Only to be used by core/arch code
103 * during early bootup (a continued line is not SMP-safe otherwise). 103 * during early bootup (a continued line is not SMP-safe otherwise).
104 */ 104 */
105#define KERN_CONT "" 105#define KERN_CONT "<c>"
106 106
107extern int console_printk[]; 107extern int console_printk[];
108 108