Linux kernel print data to serial console issues
Original source: Http://i.cnblogs.com/EditPosts.aspx?opt=1
1. View the current console's print level
Cat/proc/sys/kernel/printk
4 4 1 7
Where the first "4" represents the print level of the kernel print function PRINTK, only information that is higher than his level can be printed on the console, with 0-3 levels of information
2. Modify the printing
echo "New print Level 4 1 7" >/PROC/SYS/KERNEL/PRINTK
3, insufficient printing level of information will be written to the log can be viewed through the DMESG command
4. PRINTK Print Level
#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 * /
5, the use of PRINTK function
PRINTK ( print level "information to print") Here you need to note that there is no comma in the middle of the print level and the data that needs to be printed
Print level a few macros defined above
Linux kernel print data to serial console, PRINTK data does not print problem