drm/imx: Don't set a gamma table size
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 30 Mar 2016 09:51:23 +0000 (11:51 +0200)
committerPhilipp Zabel <p.zabel@pengutronix.de>
Thu, 31 Mar 2016 09:24:37 +0000 (11:24 +0200)
imx doesn't have any functions for setting the gamma table, so this is
completely defunct.

Not nice to lie to userspace, so let's stop!

Cc: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
drivers/gpu/drm/imx/imx-drm-core.c

index 9876e0f0c3e1833592308f1a8a38de5c3e44f2b0..e26dcdec2aba0e51233910c82f1788e49ea6f2ce 100644 (file)
@@ -326,7 +326,6 @@ int imx_drm_add_crtc(struct drm_device *drm, struct drm_crtc *crtc,
 {
        struct imx_drm_device *imxdrm = drm->dev_private;
        struct imx_drm_crtc *imx_drm_crtc;
-       int ret;
 
        /*
         * The vblank arrays are dimensioned by MAX_CRTC - we can't
@@ -351,10 +350,6 @@ int imx_drm_add_crtc(struct drm_device *drm, struct drm_crtc *crtc,
 
        *new_crtc = imx_drm_crtc;
 
-       ret = drm_mode_crtc_set_gamma_size(imx_drm_crtc->crtc, 256);
-       if (ret)
-               goto err_register;
-
        drm_crtc_helper_add(crtc,
                        imx_drm_crtc->imx_drm_helper_funcs.crtc_helper_funcs);
 
@@ -362,11 +357,6 @@ int imx_drm_add_crtc(struct drm_device *drm, struct drm_crtc *crtc,
                        imx_drm_crtc->imx_drm_helper_funcs.crtc_funcs, NULL);
 
        return 0;
-
-err_register:
-       imxdrm->crtc[--imxdrm->pipes] = NULL;
-       kfree(imx_drm_crtc);
-       return ret;
 }
 EXPORT_SYMBOL_GPL(imx_drm_add_crtc);