backlight: use pr_warn instead of printk
Subsystems (2)
PATCH 1/7 backlight: use pr_warn instead of printk
This patch uses pr_warn instead of printk to allow dynamic debugging. It also fixes checkpatch warnings as below:
WARNING: Prefer pr_warn(... to printk(KERN_WARNING, ...
Cc Richard Purdie <[email protected]>
Signed-off-by Jingoo Han <[email protected]>
--- drivers/video/backlight/backlight.c | 4 ++-- drivers/video/backlight/lcd.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)
drivers/video/backlight/backlight.c +2 -2
@@ -378,8 +378,8 @@ static int __init backlight_class_init(void) { backlight_class =class_create (THIS_MODULE ,"backlight" );if (IS_ERR (backlight_class)) { -printk (KERN_WARNING "Unable to create backlight class; errno = %ld\n" , -PTR_ERR (backlight_class)); +pr_warn ("Unable to create backlight class; errno = %ld\n" , +PTR_ERR (backlight_class));return PTR_ERR (backlight_class); }
drivers/video/backlight/lcd.c +2 -2
@@ -263,8 +263,8 @@ static int __init lcd_class_init(void) { lcd_class =class_create (THIS_MODULE ,"lcd" );if (IS_ERR (lcd_class)) { -printk (KERN_WARNING "Unable to create backlight class; errno = %ld\n" , -PTR_ERR (lcd_class)); +pr_warn ("Unable to create backlight class; errno = %ld\n" , +PTR_ERR (lcd_class));return PTR_ERR (lcd_class); }
Signature · 1 line
1.7.1