]> git.karo-electronics.de Git - karo-tx-linux.git/commit
printk: add generic functions to find KERN_<LEVEL> headers
authorJoe Perches <joe@perches.com>
Sat, 21 Jul 2012 00:54:42 +0000 (10:54 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 25 Jul 2012 03:53:13 +0000 (13:53 +1000)
commitc0609a2aa41dc80c0c679c2dacd6e01aab54474e
treef5d0962c411fd00ae2b99a5975fa0c1c5ca38ac5
parentdb417f8b52224a9559eedae0bf111023a1c930bd
printk: add generic functions to find KERN_<LEVEL> headers

The current form of a KERN_<LEVEL> is "<.>".

Add printk_get_level and printk_skip_level functions to handle these
formats.

These functions centralize tests of KERN_<LEVEL> so a future modification
can change the KERN_<LEVEL> style and shorten the number of bytes consumed
by these headers.

Signed-off-by: Joe Perches <joe@perches.com>
Cc: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/printk.h
kernel/printk.c