]> git.karo-electronics.de Git - linux-beck.git/commitdiff
drm/gma500: use DRM_FB_HELPER_DEFAULT_OPS for fb_ops
authorStefan Christ <contact@stefanchrist.eu>
Sun, 13 Nov 2016 23:03:28 +0000 (00:03 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Mon, 14 Nov 2016 07:01:01 +0000 (08:01 +0100)
This refactoring leads to real functional changes in the driver.

Now the struct psbfb_ops implements two additional members:

       .fb_setcmap     = drm_fb_helper_setcmap,
       .fb_pan_display = drm_fb_helper_pan_display,

and the struct psbfb_roll_ops implements one additional member:

       .fb_setcmap     = drm_fb_helper_setcmap,

and the struct psbfb_unaccel_ops implements two additional members:

       .fb_setcmap     = drm_fb_helper_setcmap,
       .fb_pan_display = drm_fb_helper_pan_display,

These changes are not tested.

Cc: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
Signed-off-by: Stefan Christ <contact@stefanchrist.eu>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1479078208-25221-19-git-send-email-contact@stefanchrist.eu
drivers/gpu/drm/gma500/framebuffer.c

index 97daf23f3fef70bb8c6eb05f341bfbcc41d1ce77..4071b2d1e8cfcda44d9479e0a457f312df8cdc76 100644 (file)
@@ -185,9 +185,7 @@ static int psbfb_mmap(struct fb_info *info, struct vm_area_struct *vma)
 
 static struct fb_ops psbfb_ops = {
        .owner = THIS_MODULE,
-       .fb_check_var = drm_fb_helper_check_var,
-       .fb_set_par = drm_fb_helper_set_par,
-       .fb_blank = drm_fb_helper_blank,
+       DRM_FB_HELPER_DEFAULT_OPS,
        .fb_setcolreg = psbfb_setcolreg,
        .fb_fillrect = drm_fb_helper_cfb_fillrect,
        .fb_copyarea = psbfb_copyarea,
@@ -198,9 +196,7 @@ static struct fb_ops psbfb_ops = {
 
 static struct fb_ops psbfb_roll_ops = {
        .owner = THIS_MODULE,
-       .fb_check_var = drm_fb_helper_check_var,
-       .fb_set_par = drm_fb_helper_set_par,
-       .fb_blank = drm_fb_helper_blank,
+       DRM_FB_HELPER_DEFAULT_OPS,
        .fb_setcolreg = psbfb_setcolreg,
        .fb_fillrect = drm_fb_helper_cfb_fillrect,
        .fb_copyarea = drm_fb_helper_cfb_copyarea,
@@ -211,9 +207,7 @@ static struct fb_ops psbfb_roll_ops = {
 
 static struct fb_ops psbfb_unaccel_ops = {
        .owner = THIS_MODULE,
-       .fb_check_var = drm_fb_helper_check_var,
-       .fb_set_par = drm_fb_helper_set_par,
-       .fb_blank = drm_fb_helper_blank,
+       DRM_FB_HELPER_DEFAULT_OPS,
        .fb_setcolreg = psbfb_setcolreg,
        .fb_fillrect = drm_fb_helper_cfb_fillrect,
        .fb_copyarea = drm_fb_helper_cfb_copyarea,