From: Mike Rapoport Date: Fri, 23 Oct 2015 14:55:10 +0000 (+0300) Subject: staging: sm750fb: replace lynx_crtc methods with function calls X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=c202beee7f4b2b4f363e21fea714c8afcb08b12e;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git staging: sm750fb: replace lynx_crtc methods with function calls The methods in lynx_crtc always use the same implementation and there is no point to use redirection rather than direct function call. Signed-off-by: Mike Rapoport Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c index 7eca4cb3c656..24c4f39c79b7 100644 --- a/drivers/staging/sm750fb/sm750.c +++ b/drivers/staging/sm750fb/sm750.c @@ -304,7 +304,7 @@ static int lynxfb_ops_pan_display(struct fb_var_screeninfo *var, par = info->par; crtc = &par->crtc; - return crtc->proc_panDisplay(crtc, var, info); + return hw_sm750_pan_display(crtc, var, info); } static int lynxfb_ops_set_par(struct fb_info *info) @@ -384,7 +384,7 @@ static int lynxfb_ops_set_par(struct fb_info *info) pr_err("pixel bpp format not satisfied\n."); return ret; } - ret = crtc->proc_setMode(crtc, var, fix); + ret = hw_sm750_crtc_setMode(crtc, var, fix); if (!ret) ret = output->proc_setMode(output, var, fix); return ret; @@ -581,7 +581,7 @@ static int lynxfb_ops_check_var(struct fb_var_screeninfo *var, return -ENOMEM; } - return crtc->proc_checkMode(crtc, var); + return hw_sm750_crtc_checkMode(crtc, var); } static int lynxfb_ops_setcolreg(unsigned regno, @@ -614,7 +614,7 @@ static int lynxfb_ops_setcolreg(unsigned regno, red >>= 8; green >>= 8; blue >>= 8; - ret = crtc->proc_setColReg(crtc, regno, red, green, blue); + ret = hw_sm750_setColReg(crtc, regno, red, green, blue); goto exit; } @@ -669,10 +669,6 @@ static int sm750fb_set_drv(struct lynxfb_par *par) /* setup crtc and output member */ spec_share->hwCursor = g_hwcursor; - crtc->proc_setMode = hw_sm750_crtc_setMode; - crtc->proc_checkMode = hw_sm750_crtc_checkMode; - crtc->proc_setColReg = hw_sm750_setColReg; - crtc->proc_panDisplay = hw_sm750_pan_display; crtc->line_pad = 16; crtc->xpanstep = 8; crtc->ypanstep = 1; diff --git a/drivers/staging/sm750fb/sm750.h b/drivers/staging/sm750fb/sm750.h index c18806173410..6f5e09d259aa 100644 --- a/drivers/staging/sm750fb/sm750.h +++ b/drivers/staging/sm750fb/sm750.h @@ -104,16 +104,6 @@ struct lynxfb_crtc { void *priv; - int (*proc_setMode)(struct lynxfb_crtc*, - struct fb_var_screeninfo*, - struct fb_fix_screeninfo*); - - int (*proc_checkMode)(struct lynxfb_crtc*, struct fb_var_screeninfo*); - int (*proc_setColReg)(struct lynxfb_crtc*, ushort, ushort, ushort, ushort); - /* pan display */ - int (*proc_panDisplay)(struct lynxfb_crtc *, - const struct fb_var_screeninfo *, - const struct fb_info *); /* cursor information */ struct lynx_cursor cursor; };