Linux'
kernel coding style has some notes on the preferred message format, such as
- Do not use crippled words like *dont*; use do not or don't instead
- Messages do not have to be terminated with a period.
- Printing numbers in parentheses (%d) adds no value and should be avoided.
-
<linux/dev_printk.h>
has a number macros that make sure messages are matched to the right device and driver, and are tagged with the right level: dev_err()
, dev_warn()
, dev_info()
etc. (Compare with pr_info()
, pr_warn()
, pr_err()
etc. which are defined in <linux/printk.h>
).