MLK-18045-3 drm/imx: dcss: bypass dec400d if 'compressed' is false
authorFancy Fang <chen.fang@nxp.com>
Sun, 15 Apr 2018 05:14:34 +0000 (13:14 +0800)
committerLeonard Crestez <leonard.crestez@nxp.com>
Wed, 17 Apr 2019 23:51:34 +0000 (02:51 +0300)
When the fb's modifier is 'DRM_FORMAT_MOD_VIVANTE_SUPER_TILED_FC',
the compression state can be changed to non-compress according to
the 'compressed' field value of 'struct dma_metadata' data. At this
moment, the DEC400D should be bypassed.

Signed-off-by: Fancy Fang <chen.fang@nxp.com>
drivers/gpu/drm/imx/dcss/dcss-plane.c

index 3ee75a1..8617327 100644 (file)
@@ -322,6 +322,12 @@ static void dcss_plane_atomic_set_base(struct dcss_plane *dcss_plane)
                                return;
                        }
 
+                       if (!mdata->compressed) {
+                               /* Bypass dec400d */
+                               dcss_dec400d_bypass(dcss_plane->dcss);
+                               return;
+                       }
+
                        gem_obj = dcss_plane_gem_import(plane->dev,
                                                        mdata->ts_dma_buf);
                        if (IS_ERR(gem_obj)) {