Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

video: fbcon: Fix warnings by using pr_debug() in fbcon

Replacing DPRINTK() statements with pr_debug fixes set but not used
warnings. And moves to a more standard logging setup at the same time.

v2:
- Fix indent (Joe)

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
Cc: Joe Perches <joe@perches.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: Jiri Slaby <jirislaby@kernel.org>
Cc: Peilin Ye <yepeilin.cs@gmail.com>
Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Cc: George Kennedy <george.kennedy@oracle.com>
Cc: Nathan Chancellor <natechancellor@gmail.com>
Cc: Peter Rosin <peda@axentia.se>
Link: https://patchwork.freedesktop.org/patch/msgid/20201128224114.1033617-3-sam@ravnborg.org

+8 -17
+8 -17
drivers/video/fbdev/core/fbcon.c
··· 56 56 * more details. 57 57 */ 58 58 59 - #undef FBCONDEBUG 60 - 61 59 #include <linux/module.h> 62 60 #include <linux/types.h> 63 61 #include <linux/fs.h> ··· 79 81 #include <asm/irq.h> 80 82 81 83 #include "fbcon.h" 82 - 83 - #ifdef FBCONDEBUG 84 - # define DPRINTK(fmt, args...) printk(KERN_DEBUG "%s: " fmt, __func__ , ## args) 85 - #else 86 - # define DPRINTK(fmt, args...) 87 - #endif 88 84 89 85 /* 90 86 * FIXME: Locking ··· 1007 1015 rows /= vc->vc_font.height; 1008 1016 vc_resize(vc, cols, rows); 1009 1017 1010 - DPRINTK("mode: %s\n", info->fix.id); 1011 - DPRINTK("visual: %d\n", info->fix.visual); 1012 - DPRINTK("res: %dx%d-%d\n", info->var.xres, 1013 - info->var.yres, 1014 - info->var.bits_per_pixel); 1018 + pr_debug("mode: %s\n", info->fix.id); 1019 + pr_debug("visual: %d\n", info->fix.visual); 1020 + pr_debug("res: %dx%d-%d\n", info->var.xres, 1021 + info->var.yres, 1022 + info->var.bits_per_pixel); 1015 1023 1016 1024 fbcon_add_cursor_timer(info); 1017 1025 return display_desc; ··· 2005 2013 y_diff < 0 || y_diff > virt_fh) { 2006 2014 const struct fb_videomode *mode; 2007 2015 2008 - DPRINTK("attempting resize %ix%i\n", var.xres, var.yres); 2016 + pr_debug("attempting resize %ix%i\n", var.xres, var.yres); 2009 2017 mode = fb_find_best_mode(&var, &info->modelist); 2010 2018 if (mode == NULL) 2011 2019 return -EINVAL; ··· 2015 2023 if (virt_w > var.xres/virt_fw || virt_h > var.yres/virt_fh) 2016 2024 return -EINVAL; 2017 2025 2018 - DPRINTK("resize now %ix%i\n", var.xres, var.yres); 2026 + pr_debug("resize now %ix%i\n", var.xres, var.yres); 2019 2027 if (con_is_visible(vc)) { 2020 2028 var.activate = FB_ACTIVATE_NOW | 2021 2029 FB_ACTIVATE_FORCE; ··· 3291 3299 3292 3300 if (info->queue.func) 3293 3301 pending = cancel_work_sync(&info->queue); 3294 - DPRINTK("fbcon: %s pending work\n", (pending ? "canceled" : 3295 - "no")); 3302 + pr_debug("fbcon: %s pending work\n", (pending ? "canceled" : "no")); 3296 3303 3297 3304 for (j = first_fb_vc; j <= last_fb_vc; j++) { 3298 3305 if (con2fb_map[j] == i) {