From cc59bde1c920ab6689d40eba1a6fcd4edbec2455 Mon Sep 17 00:00:00 2001 From: Benjamin Philip Date: Wed, 28 Jul 2021 00:49:53 +0530 Subject: [PATCH] staging: sm750fb: Rename vScreen to v_screen in lynxfb_crtc The struct lynxfb_crtc has a member named vScreen. This name is CamelCase and is frowned upon. This commit renames it to v_screen and makes the necessary changes for the module to build. This change also fixes the following checkpatch CHECKs: CHECK: Avoid CamelCase: 454: FILE: sm750.c:454: + memset_io(crtc->vScreen, 0x0, crtc->vidmem_size); CHECK: Avoid CamelCase: 136: FILE: sm750.h:136: + unsigned char __iomem *vScreen; /* virtual address of on_screen */ Signed-off-by: Benjamin Philip Link: https://lore.kernel.org/r/52db14bfc2f39e246aed7fdf866845a72e503b36.1627413010.git.benjamin.philip495@gmail.com Signed-off-by: Greg Kroah-Hartman --- drivers/staging/sm750fb/sm750.c | 18 +++++++++--------- drivers/staging/sm750fb/sm750.h | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c index 202d8f4..dbd1159a 100644 --- a/drivers/staging/sm750fb/sm750.c +++ b/drivers/staging/sm750fb/sm750.c @@ -451,7 +451,7 @@ static int __maybe_unused lynxfb_resume(struct device *dev) crtc = &par->crtc; cursor = &crtc->cursor; memset_io(cursor->vstart, 0x0, cursor->size); - memset_io(crtc->vScreen, 0x0, crtc->vidmem_size); + memset_io(crtc->v_screen, 0x0, crtc->vidmem_size); lynxfb_ops_set_par(info); fb_set_suspend(info, 0); } @@ -463,7 +463,7 @@ static int __maybe_unused lynxfb_resume(struct device *dev) crtc = &par->crtc; cursor = &crtc->cursor; memset_io(cursor->vstart, 0x0, cursor->size); - memset_io(crtc->vScreen, 0x0, crtc->vidmem_size); + memset_io(crtc->v_screen, 0x0, crtc->vidmem_size); lynxfb_ops_set_par(info); fb_set_suspend(info, 0); } @@ -615,27 +615,27 @@ static int sm750fb_set_drv(struct lynxfb_par *par) output->paths = sm750_pnc; crtc->channel = sm750_primary; crtc->o_screen = 0; - crtc->vScreen = sm750_dev->pvMem; + crtc->v_screen = sm750_dev->pvMem; pr_info("use simul primary mode\n"); break; case sm750_simul_sec: output->paths = sm750_pnc; crtc->channel = sm750_secondary; crtc->o_screen = 0; - crtc->vScreen = sm750_dev->pvMem; + crtc->v_screen = sm750_dev->pvMem; break; case sm750_dual_normal: if (par->index == 0) { output->paths = sm750_panel; crtc->channel = sm750_primary; crtc->o_screen = 0; - crtc->vScreen = sm750_dev->pvMem; + crtc->v_screen = sm750_dev->pvMem; } else { output->paths = sm750_crt; crtc->channel = sm750_secondary; /* not consider of padding stuffs for o_screen,need fix */ crtc->o_screen = sm750_dev->vidmem_size >> 1; - crtc->vScreen = sm750_dev->pvMem + crtc->o_screen; + crtc->v_screen = sm750_dev->pvMem + crtc->o_screen; } break; case sm750_dual_swap: @@ -643,7 +643,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par) output->paths = sm750_panel; crtc->channel = sm750_secondary; crtc->o_screen = 0; - crtc->vScreen = sm750_dev->pvMem; + crtc->v_screen = sm750_dev->pvMem; } else { output->paths = sm750_crt; crtc->channel = sm750_primary; @@ -651,7 +651,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par) * need fix */ crtc->o_screen = sm750_dev->vidmem_size >> 1; - crtc->vScreen = sm750_dev->pvMem + crtc->o_screen; + crtc->v_screen = sm750_dev->pvMem + crtc->o_screen; } break; default: @@ -801,7 +801,7 @@ static int lynxfb_set_fbinfo(struct fb_info *info, int index) crtc->line_pad); info->pseudo_palette = &par->pseudo_palette[0]; - info->screen_base = crtc->vScreen; + info->screen_base = crtc->v_screen; pr_debug("screen_base vaddr = %p\n", info->screen_base); info->screen_size = line_length * var->yres_virtual; info->flags = FBINFO_FLAG_DEFAULT | 0; diff --git a/drivers/staging/sm750fb/sm750.h b/drivers/staging/sm750fb/sm750.h index 8952154..aff6966 100644 --- a/drivers/staging/sm750fb/sm750.h +++ b/drivers/staging/sm750fb/sm750.h @@ -133,7 +133,7 @@ struct lynx_cursor { struct lynxfb_crtc { unsigned char __iomem *v_cursor; /* virtual address of cursor */ - unsigned char __iomem *vScreen; /* virtual address of on_screen */ + unsigned char __iomem *v_screen; /* virtual address of on_screen */ int o_cursor; /* cursor address offset in vidmem */ int o_screen; /* onscreen address offset in vidmem */ int channel;/* which channel this crtc stands for*/ -- 2.7.4