drm/exynos/gsc: Fix the multiple of resolution to 16 21/145121/1
authorHoegeun Kwon <hoegeun.kwon@samsung.com>
Mon, 21 Aug 2017 01:06:34 +0000 (10:06 +0900)
committerHoegeun Kwon <hoegeun.kwon@samsung.com>
Mon, 21 Aug 2017 09:48:47 +0000 (18:48 +0900)
There is a problem that multiples of 4, 8 are considered only for
certain format. Change to a multiple of 16 to accommodate all formats.

Change-Id: I56a664ea85bc136ad424dfb40e29d20e4225c481
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
drivers/gpu/drm/exynos/exynos_drm_gsc.c

index dfa536f..524203e 100644 (file)
@@ -1528,13 +1528,12 @@ static int gsc_ippdrv_check_property(struct device *dev,
                sz = &config->sz;
 
                /*
-                * Multiples of the resolution must be a multiple
-                * of 4, 8 each horizontally and vertically.
-                * Check source the resolution.
+                * Multiples of the source resolution must be a multiple of 16.
+                * Check the source resolution.
                 */
                if (i == EXYNOS_DRM_OPS_SRC &&
-                       ((sz->hsize & 0x3) || (sz->vsize & 0x7))) {
-                       DRM_ERROR("resolution must be a multiple of 4 or 8.\n");
+                       ((sz->hsize & 0xf) || (sz->vsize & 0xf))) {
+                       DRM_ERROR("resolution must be a multiple of 16.\n");
                        goto err_property;
                }