printk()include/linux/kernel.h

printk() feeds kernel messages to the
console, dmesg, and the syslog daemon. It is useful for debugging
and reporting errors, and can be used inside interrupt context,
but use with caution: a machine which has its console flooded with
printk messages is unusable. It uses a format string mostly
compatible with ANSI C printf, and C string concatenation to give
it a first "priority" argument:

printk(KERN_INFO "i = %u\n", i);

See include/linux/kernel.h;
for other KERN_ values; these are interpreted by syslog as the
level. Special case: for printing an IP address use