#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_WARNING "<4>" /* warning conditions */警告 #define KERN_NOTICE "<5>" /* normal but significant condition */普通但还是须注意 #define KERN_INFO "<6>" /* informational */ 信息 #define KERN_DEBUG "<7>" /* debug-level messages */ 调试信息
未指定优先级的默认级别定义在/kernel/printk.c中:
/* printk's without a loglevel use this.. */ #define DEFAULT_MESSAGE_LOGLEVEL 4 /* KERN_WARNING */ /* 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 */